@skmtc/core 0.0.802 → 0.0.804

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 (121) hide show
  1. package/esm/context/CoreContext.d.ts +3 -0
  2. package/esm/context/CoreContext.d.ts.map +1 -1
  3. package/esm/context/CoreContext.js +17 -12
  4. package/esm/context/GenerateContext.d.ts +2 -1
  5. package/esm/context/GenerateContext.d.ts.map +1 -1
  6. package/esm/context/ParseContext.d.ts +3 -3
  7. package/esm/context/ParseContext.d.ts.map +1 -1
  8. package/esm/context/RenderContext.d.ts +4 -1
  9. package/esm/context/RenderContext.d.ts.map +1 -1
  10. package/esm/context/RenderContext.js +11 -6
  11. package/esm/dsl/operation/OperationDriver.d.ts +36 -0
  12. package/esm/dsl/operation/OperationDriver.d.ts.map +1 -1
  13. package/esm/dsl/operation/OperationDriver.js +36 -0
  14. package/esm/dsl/operation/toOperationBase.d.ts +58 -0
  15. package/esm/dsl/operation/toOperationBase.d.ts.map +1 -1
  16. package/esm/dsl/operation/toOperationBase.js +46 -0
  17. package/esm/dsl/operation/toOperationEntry.d.ts +37 -0
  18. package/esm/dsl/operation/toOperationEntry.d.ts.map +1 -1
  19. package/esm/dsl/operation/toOperationEntry.js +28 -0
  20. package/esm/mod.d.ts +1 -0
  21. package/esm/mod.d.ts.map +1 -1
  22. package/esm/mod.js +1 -0
  23. package/esm/oas/array/Array.d.ts +26 -0
  24. package/esm/oas/array/Array.d.ts.map +1 -1
  25. package/esm/oas/array/Array.js +26 -0
  26. package/esm/oas/array/array-types.d.ts +12 -0
  27. package/esm/oas/array/array-types.d.ts.map +1 -1
  28. package/esm/oas/array/array-types.js +6 -0
  29. package/esm/oas/boolean/Boolean.d.ts +26 -0
  30. package/esm/oas/boolean/Boolean.d.ts.map +1 -1
  31. package/esm/oas/boolean/Boolean.js +26 -0
  32. package/esm/oas/boolean/toBoolean.d.ts +57 -0
  33. package/esm/oas/boolean/toBoolean.d.ts.map +1 -1
  34. package/esm/oas/boolean/toBoolean.js +57 -0
  35. package/esm/oas/number/toNumber.d.ts +62 -0
  36. package/esm/oas/number/toNumber.d.ts.map +1 -1
  37. package/esm/oas/number/toNumber.js +62 -0
  38. package/esm/oas/parameter/Parameter.d.ts +47 -0
  39. package/esm/oas/parameter/Parameter.d.ts.map +1 -1
  40. package/esm/oas/parameter/Parameter.js +47 -0
  41. package/esm/oas/ref/ref-types.d.ts +48 -0
  42. package/esm/oas/ref/ref-types.d.ts.map +1 -1
  43. package/esm/oas/ref/ref-types.js +18 -0
  44. package/esm/oas/server/Server.d.ts +72 -0
  45. package/esm/oas/server/Server.d.ts.map +1 -1
  46. package/esm/oas/server/Server.js +66 -0
  47. package/esm/types/CustomValue.d.ts +58 -0
  48. package/esm/types/CustomValue.d.ts.map +1 -1
  49. package/esm/types/CustomValue.js +58 -0
  50. package/esm/types/DenoJson.d.ts +24 -0
  51. package/esm/types/DenoJson.d.ts.map +1 -1
  52. package/esm/types/DenoJson.js +12 -0
  53. package/esm/types/Enrichments.d.ts +103 -0
  54. package/esm/types/Enrichments.d.ts.map +1 -1
  55. package/esm/types/Enrichments.js +52 -0
  56. package/esm/types/GeneratedValue.d.ts +17 -0
  57. package/esm/types/GeneratedValue.d.ts.map +1 -1
  58. package/esm/types/Logger.d.ts +9 -0
  59. package/esm/types/Logger.d.ts.map +1 -0
  60. package/esm/types/Logger.js +1 -0
  61. package/package.json +1 -1
  62. package/script/context/CoreContext.d.ts +3 -0
  63. package/script/context/CoreContext.d.ts.map +1 -1
  64. package/script/context/CoreContext.js +17 -12
  65. package/script/context/GenerateContext.d.ts +2 -1
  66. package/script/context/GenerateContext.d.ts.map +1 -1
  67. package/script/context/ParseContext.d.ts +3 -3
  68. package/script/context/ParseContext.d.ts.map +1 -1
  69. package/script/context/RenderContext.d.ts +4 -1
  70. package/script/context/RenderContext.d.ts.map +1 -1
  71. package/script/context/RenderContext.js +11 -6
  72. package/script/dsl/operation/OperationDriver.d.ts +36 -0
  73. package/script/dsl/operation/OperationDriver.d.ts.map +1 -1
  74. package/script/dsl/operation/OperationDriver.js +36 -0
  75. package/script/dsl/operation/toOperationBase.d.ts +58 -0
  76. package/script/dsl/operation/toOperationBase.d.ts.map +1 -1
  77. package/script/dsl/operation/toOperationBase.js +46 -0
  78. package/script/dsl/operation/toOperationEntry.d.ts +37 -0
  79. package/script/dsl/operation/toOperationEntry.d.ts.map +1 -1
  80. package/script/dsl/operation/toOperationEntry.js +28 -0
  81. package/script/mod.d.ts +1 -0
  82. package/script/mod.d.ts.map +1 -1
  83. package/script/mod.js +1 -0
  84. package/script/oas/array/Array.d.ts +26 -0
  85. package/script/oas/array/Array.d.ts.map +1 -1
  86. package/script/oas/array/Array.js +26 -0
  87. package/script/oas/array/array-types.d.ts +12 -0
  88. package/script/oas/array/array-types.d.ts.map +1 -1
  89. package/script/oas/array/array-types.js +6 -0
  90. package/script/oas/boolean/Boolean.d.ts +26 -0
  91. package/script/oas/boolean/Boolean.d.ts.map +1 -1
  92. package/script/oas/boolean/Boolean.js +26 -0
  93. package/script/oas/boolean/toBoolean.d.ts +57 -0
  94. package/script/oas/boolean/toBoolean.d.ts.map +1 -1
  95. package/script/oas/boolean/toBoolean.js +57 -0
  96. package/script/oas/number/toNumber.d.ts +62 -0
  97. package/script/oas/number/toNumber.d.ts.map +1 -1
  98. package/script/oas/number/toNumber.js +62 -0
  99. package/script/oas/parameter/Parameter.d.ts +47 -0
  100. package/script/oas/parameter/Parameter.d.ts.map +1 -1
  101. package/script/oas/parameter/Parameter.js +47 -0
  102. package/script/oas/ref/ref-types.d.ts +48 -0
  103. package/script/oas/ref/ref-types.d.ts.map +1 -1
  104. package/script/oas/ref/ref-types.js +18 -0
  105. package/script/oas/server/Server.d.ts +72 -0
  106. package/script/oas/server/Server.d.ts.map +1 -1
  107. package/script/oas/server/Server.js +66 -0
  108. package/script/types/CustomValue.d.ts +58 -0
  109. package/script/types/CustomValue.d.ts.map +1 -1
  110. package/script/types/CustomValue.js +58 -0
  111. package/script/types/DenoJson.d.ts +24 -0
  112. package/script/types/DenoJson.d.ts.map +1 -1
  113. package/script/types/DenoJson.js +12 -0
  114. package/script/types/Enrichments.d.ts +103 -0
  115. package/script/types/Enrichments.d.ts.map +1 -1
  116. package/script/types/Enrichments.js +52 -0
  117. package/script/types/GeneratedValue.d.ts +17 -0
  118. package/script/types/GeneratedValue.d.ts.map +1 -1
  119. package/script/types/Logger.d.ts +9 -0
  120. package/script/types/Logger.d.ts.map +1 -0
  121. package/script/types/Logger.js +2 -0
@@ -1,14 +1,39 @@
1
1
  import "../_dnt.polyfills.js";
2
2
  import { ContentBase } from '../dsl/ContentBase.js';
3
+ /**
4
+ * Represents a custom value in the SKMTC generation pipeline.
5
+ *
6
+ * CustomValue allows generators to create arbitrary content that doesn't fit
7
+ * standard schema types. Used for injecting custom code, templates, or specialized
8
+ * content during the generation process.
9
+ *
10
+ * @example Creating custom content
11
+ * ```typescript
12
+ * const customValue = new CustomValue({
13
+ * context: generateContext,
14
+ * value: 'const customCode = "generated";',
15
+ * generatorKey: 'my-generator'
16
+ * });
17
+ *
18
+ * console.log(customValue.toString()); // "const customCode = "generated";"
19
+ * ```
20
+ */
3
21
  export class CustomValue extends ContentBase {
22
+ /**
23
+ * Creates a new CustomValue instance.
24
+ *
25
+ * @param args - Creation arguments including context, value, and optional generator key
26
+ */
4
27
  constructor({ context, value, generatorKey }) {
5
28
  super({ context, generatorKey });
29
+ /** Type identifier for this custom value */
6
30
  Object.defineProperty(this, "type", {
7
31
  enumerable: true,
8
32
  configurable: true,
9
33
  writable: true,
10
34
  value: 'custom'
11
35
  });
36
+ /** The underlying value content that can be converted to string */
12
37
  Object.defineProperty(this, "value", {
13
38
  enumerable: true,
14
39
  configurable: true,
@@ -17,19 +42,52 @@ export class CustomValue extends ContentBase {
17
42
  });
18
43
  this.value = value;
19
44
  }
45
+ /**
46
+ * Determines if this custom value is a reference.
47
+ *
48
+ * @returns Always false since custom values are concrete content, not references
49
+ */
20
50
  isRef() {
21
51
  return false;
22
52
  }
53
+ /**
54
+ * Resolves this custom value.
55
+ *
56
+ * @returns The custom value itself since it's already resolved
57
+ */
23
58
  resolve() {
24
59
  return this;
25
60
  }
61
+ /**
62
+ * Resolves this custom value one level.
63
+ *
64
+ * @returns The custom value itself since it's already resolved
65
+ */
26
66
  resolveOnce() {
27
67
  return this;
28
68
  }
69
+ /**
70
+ * Converts the custom value to its string representation.
71
+ *
72
+ * @returns String representation of the underlying value
73
+ */
29
74
  toString() {
30
75
  return `${this.value}`;
31
76
  }
32
77
  }
78
+ /**
79
+ * Type guard function to check if a value is a CustomValue instance.
80
+ *
81
+ * @param value - Value to check
82
+ * @returns True if the value is a CustomValue, false otherwise
83
+ *
84
+ * @example Type checking
85
+ * ```typescript
86
+ * if (isCustomValue(someValue)) {
87
+ * console.log(someValue.value); // TypeScript knows it's a CustomValue
88
+ * }
89
+ * ```
90
+ */
33
91
  export const isCustomValue = (value) => {
34
92
  return Boolean(value && typeof value === 'object' && 'type' in value && value.type === 'custom');
35
93
  };
@@ -1,12 +1,36 @@
1
1
  import "../_dnt.polyfills.js";
2
2
  import * as v from 'valibot';
3
+ /**
4
+ * Valibot schema for root-level deno.json configuration files.
5
+ *
6
+ * Validates workspace-level deno.json files that manage multiple packages
7
+ * and define workspace-wide imports and exports.
8
+ */
3
9
  export declare const rootDenoJson: v.GenericSchema<RootDenoJson>;
10
+ /**
11
+ * Type definition for root-level deno.json configuration.
12
+ *
13
+ * Represents the structure of workspace-level deno.json files that coordinate
14
+ * multiple packages within a Deno workspace.
15
+ */
4
16
  export type RootDenoJson = {
5
17
  imports?: Record<string, string>;
6
18
  exports?: Record<string, string>;
7
19
  workspace?: string[];
8
20
  };
21
+ /**
22
+ * Valibot schema for package-level deno.json configuration files.
23
+ *
24
+ * Validates individual package deno.json files that define package-specific
25
+ * metadata, dependencies, and export configurations.
26
+ */
9
27
  export declare const packageDenoJson: v.GenericSchema<PackageDenoJson>;
28
+ /**
29
+ * Type definition for package-level deno.json configuration.
30
+ *
31
+ * Represents the structure of individual package deno.json files with
32
+ * required name/version fields and optional import/export configurations.
33
+ */
10
34
  export type PackageDenoJson = {
11
35
  name: string;
12
36
  version: string;
@@ -1 +1 @@
1
- {"version":3,"file":"DenoJson.d.ts","sourceRoot":"","sources":["../../src/types/DenoJson.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B,eAAO,MAAM,YAAY,EAAE,CAAC,CAAC,aAAa,CAAC,YAAY,CAIrD,CAAA;AAEF,MAAM,MAAM,YAAY,GAAG;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,SAAS,CAAC,EAAE,MAAM,EAAE,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,aAAa,CAAC,eAAe,CAK3D,CAAA;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,CAAA;IACf,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,CAAA;CACzC,CAAA"}
1
+ {"version":3,"file":"DenoJson.d.ts","sourceRoot":"","sources":["../../src/types/DenoJson.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B;;;;;GAKG;AACH,eAAO,MAAM,YAAY,EAAE,CAAC,CAAC,aAAa,CAAC,YAAY,CAIrD,CAAA;AAEF;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,SAAS,CAAC,EAAE,MAAM,EAAE,CAAA;CACrB,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,aAAa,CAAC,eAAe,CAK3D,CAAA;AAEF;;;;;GAKG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,CAAA;IACf,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAChC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,CAAA;CACzC,CAAA"}
@@ -1,10 +1,22 @@
1
1
  import "../_dnt.polyfills.js";
2
2
  import * as v from 'valibot';
3
+ /**
4
+ * Valibot schema for root-level deno.json configuration files.
5
+ *
6
+ * Validates workspace-level deno.json files that manage multiple packages
7
+ * and define workspace-wide imports and exports.
8
+ */
3
9
  export const rootDenoJson = v.looseObject({
4
10
  imports: v.optional(v.record(v.string(), v.string())),
5
11
  exports: v.optional(v.record(v.string(), v.string())),
6
12
  workspace: v.optional(v.array(v.string()))
7
13
  });
14
+ /**
15
+ * Valibot schema for package-level deno.json configuration files.
16
+ *
17
+ * Validates individual package deno.json files that define package-specific
18
+ * metadata, dependencies, and export configurations.
19
+ */
8
20
  export const packageDenoJson = v.looseObject({
9
21
  name: v.string(),
10
22
  version: v.string(),
@@ -1,7 +1,19 @@
1
1
  import "../_dnt.polyfills.js";
2
2
  import { type ModuleExport } from './ModuleExport.js';
3
3
  import * as v from 'valibot';
4
+ /**
5
+ * Valibot schema for form field items.
6
+ *
7
+ * Validates individual form field configurations including input components,
8
+ * labels, placeholders, and data access paths.
9
+ */
4
10
  export declare const formFieldItem: v.GenericSchema<FormFieldItem>;
11
+ /**
12
+ * Configuration for a single form field.
13
+ *
14
+ * Defines how a form field should be rendered, including its input component,
15
+ * label text, data binding path, and optional placeholder text.
16
+ */
5
17
  export type FormFieldItem = {
6
18
  id: string;
7
19
  accessorPath: string[];
@@ -9,42 +21,133 @@ export type FormFieldItem = {
9
21
  label: string;
10
22
  placeholder?: string;
11
23
  };
24
+ /**
25
+ * Valibot schema for form configurations.
26
+ *
27
+ * Validates complete form definitions including title, description,
28
+ * field configurations, and submit button labels.
29
+ */
12
30
  export declare const formItem: v.GenericSchema<FormItem>;
31
+ /**
32
+ * Configuration for a complete form.
33
+ *
34
+ * Represents a form with optional title, description, field definitions,
35
+ * and customizable submit button label.
36
+ */
13
37
  export type FormItem = {
14
38
  title?: string;
15
39
  description?: string;
16
40
  fields?: FormFieldItem[];
17
41
  submitLabel?: string;
18
42
  };
43
+ /**
44
+ * Valibot schema for table column items.
45
+ *
46
+ * Validates table column configurations including formatter components,
47
+ * labels, and data access paths.
48
+ */
19
49
  export declare const tableColumnItem: v.GenericSchema<TableColumnItem>;
50
+ /**
51
+ * Configuration for a single table column.
52
+ *
53
+ * Defines how a table column should be rendered, including its formatter
54
+ * component, display label, and data binding path.
55
+ */
20
56
  export type TableColumnItem = {
21
57
  id: string;
22
58
  accessorPath: string[];
23
59
  formatter: ModuleExport;
24
60
  label: string;
25
61
  };
62
+ /**
63
+ * Valibot schema for table configurations.
64
+ *
65
+ * Validates complete table definitions including title, description,
66
+ * and column configurations.
67
+ */
26
68
  export declare const tableItem: v.GenericSchema<TableItem>;
69
+ /**
70
+ * Configuration for a complete table.
71
+ *
72
+ * Represents a table with optional title, description, and column definitions.
73
+ */
27
74
  export type TableItem = {
28
75
  title?: string;
29
76
  description?: string;
30
77
  columns?: TableColumnItem[];
31
78
  };
79
+ /**
80
+ * Valibot schema for input items.
81
+ *
82
+ * Validates input component configurations including formatter components
83
+ * and data access paths.
84
+ */
32
85
  export declare const inputItem: v.GenericSchema<InputItem>;
86
+ /**
87
+ * Configuration for a single input component.
88
+ *
89
+ * Defines how an input should be rendered, including its formatter
90
+ * component and data binding path.
91
+ */
33
92
  export type InputItem = {
34
93
  id: string;
35
94
  accessorPath: string[];
36
95
  formatter: ModuleExport;
37
96
  };
97
+ /**
98
+ * Valibot schema for operation-level enrichments.
99
+ *
100
+ * Validates enrichment configurations that can be applied to OpenAPI operations,
101
+ * including table, form, and input component definitions.
102
+ */
38
103
  export declare const operationEnrichments: v.GenericSchema<OperationEnrichments>;
104
+ /**
105
+ * Enrichment configurations for a single OpenAPI operation.
106
+ *
107
+ * Contains optional table, form, and input configurations that can enhance
108
+ * how an operation is presented and interacted with in generated UIs.
109
+ */
39
110
  export type OperationEnrichments = {
40
111
  table?: TableItem;
41
112
  form?: FormItem;
42
113
  input?: InputItem;
43
114
  };
115
+ /**
116
+ * Valibot schema for HTTP method-level enrichments.
117
+ *
118
+ * Maps HTTP methods (GET, POST, etc.) to their operation enrichment configurations.
119
+ */
44
120
  export declare const methodEnrichments: v.GenericSchema<MethodEnrichments>;
121
+ /**
122
+ * HTTP method to operation enrichments mapping.
123
+ *
124
+ * Associates HTTP methods with their corresponding operation enrichment configurations.
125
+ */
45
126
  export type MethodEnrichments = Record<string, OperationEnrichments>;
127
+ /**
128
+ * Valibot schema for API path-level enrichments.
129
+ *
130
+ * Maps API paths to their method enrichment configurations.
131
+ */
46
132
  export declare const pathEnrichments: v.GenericSchema<PathEnrichments>;
133
+ /**
134
+ * API path to method enrichments mapping.
135
+ *
136
+ * Associates API paths with their corresponding method enrichment configurations.
137
+ */
47
138
  export type PathEnrichments = Record<string, MethodEnrichments>;
139
+ /**
140
+ * Valibot schema for generator-level enrichments.
141
+ *
142
+ * Maps generator IDs to their path enrichment configurations,
143
+ * creating a complete hierarchy of enrichment data.
144
+ */
48
145
  export declare const generatorEnrichments: v.GenericSchema<GeneratorEnrichments>;
146
+ /**
147
+ * Generator ID to path enrichments mapping.
148
+ *
149
+ * Top-level enrichment structure that organizes enrichment data by generator,
150
+ * then by path, then by HTTP method, providing complete enrichment hierarchies.
151
+ */
49
152
  export type GeneratorEnrichments = Record<string, PathEnrichments>;
50
153
  //# sourceMappingURL=Enrichments.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Enrichments.d.ts","sourceRoot":"","sources":["../../src/types/Enrichments.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,EAAgB,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AACnE,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B,eAAO,MAAM,aAAa,EAAE,CAAC,CAAC,aAAa,CAAC,aAAa,CAMvD,CAAA;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,EAAE,EAAE,MAAM,CAAA;IACV,YAAY,EAAE,MAAM,EAAE,CAAA;IACtB,KAAK,EAAE,YAAY,CAAA;IACnB,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,CAAC,CAAC,aAAa,CAAC,QAAQ,CAK7C,CAAA;AAEF,MAAM,MAAM,QAAQ,GAAG;IACrB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,MAAM,CAAC,EAAE,aAAa,EAAE,CAAA;IACxB,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,aAAa,CAAC,eAAe,CAK3D,CAAA;AAEF,MAAM,MAAM,eAAe,GAAG;IAC5B,EAAE,EAAE,MAAM,CAAA;IACV,YAAY,EAAE,MAAM,EAAE,CAAA;IACtB,SAAS,EAAE,YAAY,CAAA;IACvB,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAED,eAAO,MAAM,SAAS,EAAE,CAAC,CAAC,aAAa,CAAC,SAAS,CAI/C,CAAA;AAEF,MAAM,MAAM,SAAS,GAAG;IACtB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,WAAW,CAAC,EAA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,MAAM,CAAA;IACV,YAAY,EAAE,MAAM,EAAE,CAAA;IACtB,SAAS,EAAE,YAAY,CAAA;CACxB,CAAA;AAED;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,EAAE,CAAC,CAAC,aAAa,CAAC,oBAAoB,CAIrE,CAAA;AAEF;;;;;GAKG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,IAAI,CAAC,EAAE,QAAQ,CAAA;IACf,KAAK,CAAC,EAAE,SAAS,CAAA;CAClB,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,EAAE,CAAC,CAAC,aAAa,CAAC,iBAAiB,CAA8C,CAAA;AAE/G;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC,CAAA;AAEpE;;;;GAIG;AACH,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,aAAa,CAAC,eAAe,CAA2C,CAAA;AAExG;;;;GAIG;AACH,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,EAAE,iBAAiB,CAAC,CAAA;AAE/D;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,EAAE,CAAC,CAAC,aAAa,CAAC,oBAAoB,CAAyC,CAAA;AAEhH;;;;;GAKG;AACH,MAAM,MAAM,oBAAoB,GAAG,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,CAAA"}
@@ -1,6 +1,12 @@
1
1
  import "../_dnt.polyfills.js";
2
2
  import { moduleExport } from './ModuleExport.js';
3
3
  import * as v from 'valibot';
4
+ /**
5
+ * Valibot schema for form field items.
6
+ *
7
+ * Validates individual form field configurations including input components,
8
+ * labels, placeholders, and data access paths.
9
+ */
4
10
  export const formFieldItem = v.object({
5
11
  id: v.string(),
6
12
  accessorPath: v.array(v.string()),
@@ -8,33 +14,79 @@ export const formFieldItem = v.object({
8
14
  label: v.string(),
9
15
  placeholder: v.optional(v.string())
10
16
  });
17
+ /**
18
+ * Valibot schema for form configurations.
19
+ *
20
+ * Validates complete form definitions including title, description,
21
+ * field configurations, and submit button labels.
22
+ */
11
23
  export const formItem = v.object({
12
24
  title: v.optional(v.string()),
13
25
  description: v.optional(v.string()),
14
26
  fields: v.optional(v.array(formFieldItem)),
15
27
  submitLabel: v.optional(v.string())
16
28
  });
29
+ /**
30
+ * Valibot schema for table column items.
31
+ *
32
+ * Validates table column configurations including formatter components,
33
+ * labels, and data access paths.
34
+ */
17
35
  export const tableColumnItem = v.object({
18
36
  id: v.string(),
19
37
  accessorPath: v.array(v.string()),
20
38
  formatter: moduleExport,
21
39
  label: v.string()
22
40
  });
41
+ /**
42
+ * Valibot schema for table configurations.
43
+ *
44
+ * Validates complete table definitions including title, description,
45
+ * and column configurations.
46
+ */
23
47
  export const tableItem = v.object({
24
48
  title: v.optional(v.string()),
25
49
  description: v.optional(v.string()),
26
50
  columns: v.optional(v.array(tableColumnItem))
27
51
  });
52
+ /**
53
+ * Valibot schema for input items.
54
+ *
55
+ * Validates input component configurations including formatter components
56
+ * and data access paths.
57
+ */
28
58
  export const inputItem = v.object({
29
59
  id: v.string(),
30
60
  accessorPath: v.array(v.string()),
31
61
  formatter: moduleExport
32
62
  });
63
+ /**
64
+ * Valibot schema for operation-level enrichments.
65
+ *
66
+ * Validates enrichment configurations that can be applied to OpenAPI operations,
67
+ * including table, form, and input component definitions.
68
+ */
33
69
  export const operationEnrichments = v.object({
34
70
  table: v.optional(tableItem),
35
71
  form: v.optional(formItem),
36
72
  input: v.optional(inputItem)
37
73
  });
74
+ /**
75
+ * Valibot schema for HTTP method-level enrichments.
76
+ *
77
+ * Maps HTTP methods (GET, POST, etc.) to their operation enrichment configurations.
78
+ */
38
79
  export const methodEnrichments = v.record(v.string(), operationEnrichments);
80
+ /**
81
+ * Valibot schema for API path-level enrichments.
82
+ *
83
+ * Maps API paths to their method enrichment configurations.
84
+ */
39
85
  export const pathEnrichments = v.record(v.string(), methodEnrichments);
86
+ /**
87
+ * Valibot schema for generator-level enrichments.
88
+ *
89
+ * Maps generator IDs to their path enrichment configurations,
90
+ * creating a complete hierarchy of enrichment data.
91
+ */
40
92
  export const generatorEnrichments = v.record(v.string(), pathEnrichments);
@@ -12,8 +12,25 @@ import type { GeneratorKey } from './GeneratorKeys.js';
12
12
  * 'regular' - will generate content only if it is selected.
13
13
  */
14
14
  export type GenerationType = 'force' | 'regular';
15
+ /**
16
+ * Represents a value that can be generated by the SKMTC pipeline.
17
+ *
18
+ * Combines the Stringable interface with optional generator key metadata,
19
+ * allowing generated content to be associated with specific generators for
20
+ * tracking and organization purposes.
21
+ */
15
22
  export type GeneratedValue = Stringable & {
16
23
  generatorKey?: GeneratorKey;
17
24
  };
25
+ /**
26
+ * Conditional type for generated definitions based on generation type.
27
+ *
28
+ * When generation type is 'force', always returns a Definition.
29
+ * When generation type is 'regular', returns Definition or undefined
30
+ * based on whether the content is selected for generation.
31
+ *
32
+ * @template V - The generated value type extending GeneratedValue
33
+ * @template T - The generation type ('force' or 'regular')
34
+ */
18
35
  export type GeneratedDefinition<V extends GeneratedValue, T extends GenerationType> = T extends 'force' ? Definition<V> : Definition<V> | undefined;
19
36
  //# sourceMappingURL=GeneratedValue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"GeneratedValue.d.ts","sourceRoot":"","sources":["../../src/types/GeneratedValue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAEtD;;;;;;;;;GASG;AAEH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,CAAA;AAEhD,MAAM,MAAM,cAAc,GAAG,UAAU,GAAG;IACxC,YAAY,CAAC,EAAE,YAAY,CAAA;CAC5B,CAAA;AAED,MAAM,MAAM,mBAAmB,CAC7B,CAAC,SAAS,cAAc,EACxB,CAAC,SAAS,cAAc,IACtB,CAAC,SAAS,OAAO,GAAG,UAAU,CAAC,CAAC,CAAC,GAAG,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,CAAA"}
1
+ {"version":3,"file":"GeneratedValue.d.ts","sourceRoot":"","sources":["../../src/types/GeneratedValue.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAEtD;;;;;;;;;GASG;AAEH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,CAAA;AAEhD;;;;;;GAMG;AACH,MAAM,MAAM,cAAc,GAAG,UAAU,GAAG;IACxC,YAAY,CAAC,EAAE,YAAY,CAAA;CAC5B,CAAA;AAED;;;;;;;;;GASG;AACH,MAAM,MAAM,mBAAmB,CAC7B,CAAC,SAAS,cAAc,EACxB,CAAC,SAAS,cAAc,IACtB,CAAC,SAAS,OAAO,GAAG,UAAU,CAAC,CAAC,CAAC,GAAG,UAAU,CAAC,CAAC,CAAC,GAAG,SAAS,CAAA"}
@@ -0,0 +1,9 @@
1
+ import type * as log from '../deps/jsr.io/@std/log/0.224.14/mod.js';
2
+ /**
3
+ * Logger type alias for SKMTC operations.
4
+ *
5
+ * Re-exports the @std/log Logger type to maintain public API compatibility
6
+ * while providing type-safe logging throughout the SKMTC pipeline.
7
+ */
8
+ export type Logger = log.Logger;
9
+ //# sourceMappingURL=Logger.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Logger.d.ts","sourceRoot":"","sources":["../../src/types/Logger.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,GAAG,MAAM,yCAAyC,CAAA;AAEnE;;;;;GAKG;AACH,MAAM,MAAM,MAAM,GAAG,GAAG,CAAC,MAAM,CAAA"}
@@ -0,0 +1 @@
1
+ export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skmtc/core",
3
- "version": "0.0.802",
3
+ "version": "0.0.804",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/skmtc/skmtc.git"
@@ -5,6 +5,7 @@ import type { PrettierConfigType } from '../types/PrettierConfig.js';
5
5
  import type { OasDocument } from '../oas/document/Document.js';
6
6
  import type { ClientSettings } from '../types/Settings.js';
7
7
  import type { ResultType } from '../types/Results.js';
8
+ import type { Logger } from '../types/Logger.js';
8
9
  import type { GeneratorsMapContainer } from '../types/GeneratorType.js';
9
10
  import type { OpenAPIV3 } from 'openapi-types';
10
11
  import type { RenderResult } from './types.js';
@@ -122,6 +123,8 @@ export type ToArtifactsArgs = {
122
123
  */
123
124
  export declare class CoreContext {
124
125
  #private;
126
+ /** Logger instance for the context */
127
+ logger: Logger;
125
128
  /** Whether to suppress console output */
126
129
  silent: boolean;
127
130
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"CoreContext.d.ts","sourceRoot":"","sources":["../../src/context/CoreContext.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AACtD,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAA;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAA;AACpE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAA;AAC9D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAC1D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AASrD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAA;AAEvE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAE9C,OAAO,KAAK,EAA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BG;IACH,oBAAoB,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI;CAkB/C;AAED;;;;;GAKG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,sEAAsE;IACtE,SAAS,EAAE;QACT,yBAAyB;QACzB,SAAS,EAAE,MAAM,CAAA;QACjB,6CAA6C;QAC7C,QAAQ,EAAE,IAAI,CAAA;QACd,sBAAsB;QACtB,GAAG,EAAE,MAAM,CAAA;QACX,+BAA+B;QAC/B,IAAI,EAAE,OAAO,EAAE,CAAA;KAChB,CAAA;IACD,gEAAgE;IAChE,UAAU,EAAE,MAAM,CAAA;CACnB,CAAA;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,wBAAgB,cAAc,CAAC,EAAE,SAAS,EAAE,UAAU,EAAE,EAAE,iBAAiB,GAAG,MAAM,CAQnF"}
@@ -43,7 +43,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
43
43
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
44
44
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
45
45
  };
46
- var _CoreContext_instances, _CoreContext_logger, _CoreContext_phase, _CoreContext_results, _CoreContext_stackTrail, _CoreContext_setupLogger, _CoreContext_setupParsePhase, _CoreContext_setupGeneratePhase, _CoreContext_setupRenderPhase;
46
+ var _CoreContext_instances, _CoreContext_phase, _CoreContext_results, _CoreContext_stackTrail, _CoreContext_setupLogger, _CoreContext_setupParsePhase, _CoreContext_setupGeneratePhase, _CoreContext_setupRenderPhase;
47
47
  Object.defineProperty(exports, "__esModule", { value: true });
48
48
  exports.CoreContext = void 0;
49
49
  exports.skmtcFormatter = skmtcFormatter;
@@ -131,7 +131,12 @@ class CoreContext {
131
131
  constructor({ spanId, logsPath, silent }) {
132
132
  _CoreContext_instances.add(this);
133
133
  /** Logger instance for the context */
134
- _CoreContext_logger.set(this, void 0);
134
+ Object.defineProperty(this, "logger", {
135
+ enumerable: true,
136
+ configurable: true,
137
+ writable: true,
138
+ value: void 0
139
+ });
135
140
  /** Current execution phase for pipeline tracking */
136
141
  _CoreContext_phase.set(this, void 0);
137
142
  /** Results log for tracking generation outcomes */
@@ -147,7 +152,7 @@ class CoreContext {
147
152
  });
148
153
  __classPrivateFieldSet(this, _CoreContext_stackTrail, new StackTrail_js_1.StackTrail([spanId]), "f");
149
154
  __classPrivateFieldSet(this, _CoreContext_results, new ResultsLog_js_1.ResultsLog(), "f");
150
- __classPrivateFieldSet(this, _CoreContext_logger, __classPrivateFieldGet(this, _CoreContext_instances, "m", _CoreContext_setupLogger).call(this, { spanId, logsPath }), "f");
155
+ this.logger = __classPrivateFieldGet(this, _CoreContext_instances, "m", _CoreContext_setupLogger).call(this, { spanId, logsPath });
151
156
  this.silent = silent;
152
157
  }
153
158
  /**
@@ -274,7 +279,7 @@ class CoreContext {
274
279
  }), "f");
275
280
  return __classPrivateFieldGet(this, _CoreContext_phase, "f").context.toArtifacts();
276
281
  });
277
- __classPrivateFieldGet(this, _CoreContext_logger, "f").debug(`${files.size} files generated`);
282
+ this.logger.debug(`${files.size} files generated`);
278
283
  const renderOutput = await this.trace('render', async () => {
279
284
  __classPrivateFieldSet(this, _CoreContext_phase, __classPrivateFieldGet(this, _CoreContext_instances, "m", _CoreContext_setupRenderPhase).call(this, {
280
285
  files,
@@ -292,7 +297,7 @@ class CoreContext {
292
297
  }
293
298
  catch (error) {
294
299
  console.error(error);
295
- __classPrivateFieldGet(this, _CoreContext_logger, "f").error(error);
300
+ this.logger.error(error);
296
301
  Sentry.captureException(error);
297
302
  return {
298
303
  artifacts: {},
@@ -303,7 +308,7 @@ class CoreContext {
303
308
  };
304
309
  }
305
310
  finally {
306
- __classPrivateFieldGet(this, _CoreContext_logger, "f").handlers.forEach(handler => {
311
+ this.logger.handlers.forEach(handler => {
307
312
  if (handler instanceof log.FileHandler) {
308
313
  handler.flush();
309
314
  }
@@ -340,8 +345,8 @@ class CoreContext {
340
345
  */
341
346
  trace(token, fn) {
342
347
  console.log('trace', token);
343
- __classPrivateFieldGet(this, _CoreContext_logger, "f").info('trace', token);
344
- return (0, tracer_js_1.tracer)(__classPrivateFieldGet(this, _CoreContext_stackTrail, "f"), token, fn, __classPrivateFieldGet(this, _CoreContext_logger, "f"));
348
+ this.logger.info('trace', token);
349
+ return (0, tracer_js_1.tracer)(__classPrivateFieldGet(this, _CoreContext_stackTrail, "f"), token, fn, this.logger);
345
350
  }
346
351
  /**
347
352
  * Captures a result at the current execution position in the stack trail.
@@ -376,7 +381,7 @@ class CoreContext {
376
381
  }
377
382
  }
378
383
  exports.CoreContext = CoreContext;
379
- _CoreContext_logger = new WeakMap(), _CoreContext_phase = new WeakMap(), _CoreContext_results = new WeakMap(), _CoreContext_stackTrail = new WeakMap(), _CoreContext_instances = new WeakSet(), _CoreContext_setupLogger = function _CoreContext_setupLogger({ spanId, logsPath }) {
384
+ _CoreContext_phase = new WeakMap(), _CoreContext_results = new WeakMap(), _CoreContext_stackTrail = new WeakMap(), _CoreContext_instances = new WeakSet(), _CoreContext_setupLogger = function _CoreContext_setupLogger({ spanId, logsPath }) {
380
385
  const filename = (0, join_js_1.join)(logsPath ?? '', `${spanId}.txt`);
381
386
  log.setup({
382
387
  handlers: {
@@ -415,7 +420,7 @@ _CoreContext_logger = new WeakMap(), _CoreContext_phase = new WeakMap(), _CoreCo
415
420
  }, _CoreContext_setupParsePhase = function _CoreContext_setupParsePhase(documentObject) {
416
421
  const parseContext = new ParseContext_js_1.ParseContext({
417
422
  documentObject,
418
- logger: __classPrivateFieldGet(this, _CoreContext_logger, "f"),
423
+ logger: this.logger,
419
424
  stackTrail: __classPrivateFieldGet(this, _CoreContext_stackTrail, "f"),
420
425
  silent: this.silent
421
426
  });
@@ -424,7 +429,7 @@ _CoreContext_logger = new WeakMap(), _CoreContext_phase = new WeakMap(), _CoreCo
424
429
  const generateContext = new GenerateContext_js_1.GenerateContext({
425
430
  oasDocument,
426
431
  settings,
427
- logger: __classPrivateFieldGet(this, _CoreContext_logger, "f"),
432
+ logger: this.logger,
428
433
  stackTrail: __classPrivateFieldGet(this, _CoreContext_stackTrail, "f"),
429
434
  captureCurrentResult: this.captureCurrentResult.bind(this),
430
435
  toGeneratorConfigMap
@@ -437,7 +442,7 @@ _CoreContext_logger = new WeakMap(), _CoreContext_phase = new WeakMap(), _CoreCo
437
442
  mappings,
438
443
  prettierConfig: prettier,
439
444
  basePath,
440
- logger: __classPrivateFieldGet(this, _CoreContext_logger, "f"),
445
+ logger: this.logger,
441
446
  stackTrail: __classPrivateFieldGet(this, _CoreContext_stackTrail, "f"),
442
447
  captureCurrentResult: this.captureCurrentResult.bind(this)
443
448
  });
@@ -12,6 +12,7 @@ import type { GenerationType, GeneratedValue } from '../types/GeneratedValue.js'
12
12
  import { ContentSettings } from '../dsl/ContentSettings.js';
13
13
  import type { RefName } from '../types/RefName.js';
14
14
  import type * as log from '../deps/jsr.io/@std/log/0.224.14/mod.js';
15
+ import type { Logger } from '../types/Logger.js';
15
16
  import type { ResultType } from '../types/Results.js';
16
17
  import type { StackTrail } from './StackTrail.js';
17
18
  import type { Identifier } from '../dsl/Identifier.js';
@@ -383,7 +384,7 @@ export declare class GenerateContext {
383
384
  /** Client settings for customization (optional) */
384
385
  settings: ClientSettings | undefined;
385
386
  /** Logger instance for tracking generation progress */
386
- logger: log.Logger;
387
+ logger: Logger;
387
388
  /** Function to capture processing results at current stack position */
388
389
  captureCurrentResult: (result: ResultType) => void;
389
390
  /** Function that returns the generator configuration map */