@skmtc/core 0.0.807 → 0.0.809

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 (55) hide show
  1. package/esm/oas/array/array-types.d.ts +238 -25
  2. package/esm/oas/array/array-types.d.ts.map +1 -1
  3. package/esm/oas/array/array-types.js +97 -5
  4. package/esm/oas/boolean/boolean-types.d.ts +81 -9
  5. package/esm/oas/boolean/boolean-types.d.ts.map +1 -1
  6. package/esm/oas/boolean/boolean-types.js +32 -2
  7. package/esm/oas/contact/contact-types.d.ts +176 -0
  8. package/esm/oas/contact/contact-types.d.ts.map +1 -1
  9. package/esm/oas/contact/contact-types.js +102 -0
  10. package/esm/oas/mediaType/toMediaTypeItemV3.d.ts +288 -0
  11. package/esm/oas/mediaType/toMediaTypeItemV3.d.ts.map +1 -1
  12. package/esm/oas/mediaType/toMediaTypeItemV3.js +272 -0
  13. package/esm/oas/operation/operation-types.d.ts +251 -0
  14. package/esm/oas/operation/operation-types.d.ts.map +1 -1
  15. package/esm/oas/operation/operation-types.js +98 -0
  16. package/esm/oas/string/string-types.d.ts +192 -18
  17. package/esm/oas/string/string-types.d.ts.map +1 -1
  18. package/esm/oas/string/string-types.js +76 -4
  19. package/esm/types/ModuleExport.d.ts +130 -0
  20. package/esm/types/ModuleExport.d.ts.map +1 -1
  21. package/esm/types/ModuleExport.js +36 -0
  22. package/esm/types/PrettierConfig.d.ts +74 -0
  23. package/esm/types/PrettierConfig.d.ts.map +1 -1
  24. package/esm/types/PrettierConfig.js +74 -0
  25. package/esm/types/Results.d.ts +97 -0
  26. package/esm/types/Results.d.ts.map +1 -1
  27. package/esm/types/Results.js +97 -0
  28. package/package.json +1 -1
  29. package/script/oas/array/array-types.d.ts +238 -25
  30. package/script/oas/array/array-types.d.ts.map +1 -1
  31. package/script/oas/array/array-types.js +97 -5
  32. package/script/oas/boolean/boolean-types.d.ts +81 -9
  33. package/script/oas/boolean/boolean-types.d.ts.map +1 -1
  34. package/script/oas/boolean/boolean-types.js +32 -2
  35. package/script/oas/contact/contact-types.d.ts +176 -0
  36. package/script/oas/contact/contact-types.d.ts.map +1 -1
  37. package/script/oas/contact/contact-types.js +102 -0
  38. package/script/oas/mediaType/toMediaTypeItemV3.d.ts +288 -0
  39. package/script/oas/mediaType/toMediaTypeItemV3.d.ts.map +1 -1
  40. package/script/oas/mediaType/toMediaTypeItemV3.js +272 -0
  41. package/script/oas/operation/operation-types.d.ts +251 -0
  42. package/script/oas/operation/operation-types.d.ts.map +1 -1
  43. package/script/oas/operation/operation-types.js +98 -0
  44. package/script/oas/string/string-types.d.ts +192 -18
  45. package/script/oas/string/string-types.d.ts.map +1 -1
  46. package/script/oas/string/string-types.js +76 -4
  47. package/script/types/ModuleExport.d.ts +130 -0
  48. package/script/types/ModuleExport.d.ts.map +1 -1
  49. package/script/types/ModuleExport.js +36 -0
  50. package/script/types/PrettierConfig.d.ts +74 -0
  51. package/script/types/PrettierConfig.d.ts.map +1 -1
  52. package/script/types/PrettierConfig.js +74 -0
  53. package/script/types/Results.d.ts +97 -0
  54. package/script/types/Results.d.ts.map +1 -1
  55. package/script/types/Results.js +97 -0
@@ -38,8 +38,34 @@ const v = __importStar(require("valibot"));
38
38
  /**
39
39
  * Valibot enum schema for valid OpenAPI string format values.
40
40
  *
41
- * Defines the standard string formats supported by OpenAPI v3,
42
- * including date/time formats, network formats, and encoding formats.
41
+ * This schema validates that string format values conform to the OpenAPI v3
42
+ * specification's standard format identifiers. It includes date/time formats,
43
+ * network address formats, and encoding formats that provide semantic meaning
44
+ * for string validation and UI generation.
45
+ *
46
+ * @example Validating string formats
47
+ * ```typescript
48
+ * import { stringFormat } from '@skmtc/core/oas/string';
49
+ * import * as v from 'valibot';
50
+ *
51
+ * const validFormat = v.parse(stringFormat, 'email'); // 'email'
52
+ * const invalidFormat = v.parse(stringFormat, 'invalid'); // Throws ValiError
53
+ * ```
54
+ *
55
+ * @example Using in schema validation
56
+ * ```typescript
57
+ * const schema = {
58
+ * type: 'string',
59
+ * format: 'email',
60
+ * description: 'User email address'
61
+ * };
62
+ *
63
+ * // Validate the format field
64
+ * if (schema.format) {
65
+ * const validatedFormat = v.parse(stringFormat, schema.format);
66
+ * console.log(`Valid format: ${validatedFormat}`);
67
+ * }
68
+ * ```
43
69
  */
44
70
  exports.stringFormat = v.enum({
45
71
  'date-time': 'date-time',
@@ -60,8 +86,54 @@ exports.stringFormat = v.enum({
60
86
  /**
61
87
  * Valibot schema for validating OpenAPI string data objects.
62
88
  *
63
- * Validates string schema objects including length constraints,
64
- * pattern validation, format specifiers, and enumeration values.
89
+ * This comprehensive schema validates OpenAPI string schemas according to the
90
+ * OpenAPI v3 specification, including all standard properties like length
91
+ * constraints, pattern validation, format specifiers, enumeration values,
92
+ * and metadata fields. Used throughout the SKMTC pipeline for runtime
93
+ * validation of string schema definitions.
94
+ *
95
+ * @example Validating a basic string schema
96
+ * ```typescript
97
+ * import { oasStringData } from '@skmtc/core/oas/string';
98
+ * import * as v from 'valibot';
99
+ *
100
+ * const schema = {
101
+ * type: 'string',
102
+ * description: 'User name',
103
+ * minLength: 1,
104
+ * maxLength: 100,
105
+ * pattern: '^[a-zA-Z\\s]+$'
106
+ * };
107
+ *
108
+ * const validated = v.parse(oasStringData, schema);
109
+ * console.log(validated.minLength); // 1
110
+ * ```
111
+ *
112
+ * @example Validating formatted strings
113
+ * ```typescript
114
+ * const emailSchema = {
115
+ * type: 'string',
116
+ * format: 'email',
117
+ * title: 'Email Address',
118
+ * example: 'user@example.com'
119
+ * };
120
+ *
121
+ * const result = v.parse(oasStringData, emailSchema);
122
+ * console.log(result.format); // 'email'
123
+ * ```
124
+ *
125
+ * @example Validating enumerated strings
126
+ * ```typescript
127
+ * const statusSchema = {
128
+ * type: 'string',
129
+ * enum: ['pending', 'approved', 'rejected'],
130
+ * default: 'pending',
131
+ * description: 'Application status'
132
+ * };
133
+ *
134
+ * const validated = v.parse(oasStringData, statusSchema);
135
+ * console.log(validated.enum); // ['pending', 'approved', 'rejected']
136
+ * ```
65
137
  */
66
138
  exports.oasStringData = v.object({
67
139
  type: v.literal('string'),
@@ -1,8 +1,138 @@
1
1
  import "../_dnt.polyfills.js";
2
2
  import * as v from 'valibot';
3
+ /**
4
+ * Valibot schema for validating module export configuration objects.
5
+ *
6
+ * This schema validates module export structures used throughout the SKMTC
7
+ * code generation pipeline. Module exports define how generated code modules
8
+ * are exposed and imported, specifying both the export name and the file path
9
+ * where the export can be found.
10
+ *
11
+ * @example Validating a basic module export
12
+ * ```typescript
13
+ * import { moduleExport } from '@skmtc/core/types';
14
+ * import * as v from 'valibot';
15
+ *
16
+ * const config = {
17
+ * exportName: 'UserApi',
18
+ * exportPath: './generated/UserApi.ts'
19
+ * };
20
+ *
21
+ * const validated = v.parse(moduleExport, config);
22
+ * console.log(validated.exportName); // 'UserApi'
23
+ * ```
24
+ *
25
+ * @example Validating multiple exports
26
+ * ```typescript
27
+ * const exports = [
28
+ * { exportName: 'createUser', exportPath: './api/users.ts' },
29
+ * { exportName: 'updateUser', exportPath: './api/users.ts' },
30
+ * { exportName: 'UserModel', exportPath: './models/User.ts' }
31
+ * ];
32
+ *
33
+ * exports.forEach(exp => {
34
+ * const validated = v.parse(moduleExport, exp);
35
+ * console.log(`Export: ${validated.exportName} from ${validated.exportPath}`);
36
+ * });
37
+ * ```
38
+ */
3
39
  export declare const moduleExport: v.GenericSchema<ModuleExport>;
40
+ /**
41
+ * Configuration object for module exports in the SKMTC pipeline.
42
+ *
43
+ * This type defines the structure for describing how generated code modules
44
+ * should be exported and made available for import. It's used throughout
45
+ * the SKMTC system for organizing generated code, managing dependencies,
46
+ * and creating proper import/export relationships between generated files.
47
+ *
48
+ * ## Usage in SKMTC Pipeline
49
+ *
50
+ * This type is used by:
51
+ * - Code generators to define export configurations
52
+ * - File processors to organize generated modules
53
+ * - Import managers to resolve module dependencies
54
+ * - Build systems to understand code structure
55
+ *
56
+ * @example Basic module export definition
57
+ * ```typescript
58
+ * import type { ModuleExport } from '@skmtc/core/types';
59
+ *
60
+ * const apiExport: ModuleExport = {
61
+ * exportName: 'UserApiClient',
62
+ * exportPath: './generated/api/UserApiClient.ts'
63
+ * };
64
+ *
65
+ * console.log(`Import ${apiExport.exportName} from '${apiExport.exportPath}'`);
66
+ * // Import UserApiClient from './generated/api/UserApiClient.ts'
67
+ * ```
68
+ *
69
+ * @example Function export configuration
70
+ * ```typescript
71
+ * const functionExport: ModuleExport = {
72
+ * exportName: 'validateUserData',
73
+ * exportPath: './generated/validators/userValidation.ts'
74
+ * };
75
+ *
76
+ * // Used to generate: export { validateUserData } from './generated/validators/userValidation.ts'
77
+ * ```
78
+ *
79
+ * @example Type export configuration
80
+ * ```typescript
81
+ * const typeExport: ModuleExport = {
82
+ * exportName: 'UserType',
83
+ * exportPath: './generated/types/User.ts'
84
+ * };
85
+ *
86
+ * // Used to generate: export type { UserType } from './generated/types/User.ts'
87
+ * ```
88
+ *
89
+ * @example Multiple exports from same file
90
+ * ```typescript
91
+ * const userModuleExports: ModuleExport[] = [
92
+ * {
93
+ * exportName: 'User',
94
+ * exportPath: './generated/models/User.ts'
95
+ * },
96
+ * {
97
+ * exportName: 'UserValidator',
98
+ * exportPath: './generated/models/User.ts'
99
+ * },
100
+ * {
101
+ * exportName: 'createUser',
102
+ * exportPath: './generated/models/User.ts'
103
+ * }
104
+ * ];
105
+ *
106
+ * // All exports reference the same file but different symbols
107
+ * ```
108
+ *
109
+ * @example Integration with build systems
110
+ * ```typescript
111
+ * class ModuleRegistry {
112
+ * private exports: ModuleExport[] = [];
113
+ *
114
+ * addExport(moduleExport: ModuleExport) {
115
+ * this.exports.push(moduleExport);
116
+ * }
117
+ *
118
+ * generateIndexFile(): string {
119
+ * return this.exports
120
+ * .map(exp => `export { ${exp.exportName} } from '${exp.exportPath}';`)
121
+ * .join('\n');
122
+ * }
123
+ * }
124
+ *
125
+ * const registry = new ModuleRegistry();
126
+ * registry.addExport({
127
+ * exportName: 'ApiClient',
128
+ * exportPath: './api/client.ts'
129
+ * });
130
+ * ```
131
+ */
4
132
  export type ModuleExport = {
133
+ /** The name of the symbol being exported (function, class, type, etc.) */
5
134
  exportName: string;
135
+ /** The file path where the export can be found */
6
136
  exportPath: string;
7
137
  };
8
138
  //# sourceMappingURL=ModuleExport.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ModuleExport.d.ts","sourceRoot":"","sources":["../../src/types/ModuleExport.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B,eAAO,MAAM,YAAY,EAAE,CAAC,CAAC,aAAa,CAAC,YAAY,CAGrD,CAAA;AAEF,MAAM,MAAM,YAAY,GAAG;IACzB,UAAU,EAAE,MAAM,CAAA;IAClB,UAAU,EAAE,MAAM,CAAA;CACnB,CAAA"}
1
+ {"version":3,"file":"ModuleExport.d.ts","sourceRoot":"","sources":["../../src/types/ModuleExport.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,eAAO,MAAM,YAAY,EAAE,CAAC,CAAC,aAAa,CAAC,YAAY,CAGrD,CAAA;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2FG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,0EAA0E;IAC1E,UAAU,EAAE,MAAM,CAAA;IAClB,kDAAkD;IAClD,UAAU,EAAE,MAAM,CAAA;CACnB,CAAA"}
@@ -36,6 +36,42 @@ Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.moduleExport = void 0;
37
37
  require("../_dnt.polyfills.js");
38
38
  const v = __importStar(require("valibot"));
39
+ /**
40
+ * Valibot schema for validating module export configuration objects.
41
+ *
42
+ * This schema validates module export structures used throughout the SKMTC
43
+ * code generation pipeline. Module exports define how generated code modules
44
+ * are exposed and imported, specifying both the export name and the file path
45
+ * where the export can be found.
46
+ *
47
+ * @example Validating a basic module export
48
+ * ```typescript
49
+ * import { moduleExport } from '@skmtc/core/types';
50
+ * import * as v from 'valibot';
51
+ *
52
+ * const config = {
53
+ * exportName: 'UserApi',
54
+ * exportPath: './generated/UserApi.ts'
55
+ * };
56
+ *
57
+ * const validated = v.parse(moduleExport, config);
58
+ * console.log(validated.exportName); // 'UserApi'
59
+ * ```
60
+ *
61
+ * @example Validating multiple exports
62
+ * ```typescript
63
+ * const exports = [
64
+ * { exportName: 'createUser', exportPath: './api/users.ts' },
65
+ * { exportName: 'updateUser', exportPath: './api/users.ts' },
66
+ * { exportName: 'UserModel', exportPath: './models/User.ts' }
67
+ * ];
68
+ *
69
+ * exports.forEach(exp => {
70
+ * const validated = v.parse(moduleExport, exp);
71
+ * console.log(`Export: ${validated.exportName} from ${validated.exportPath}`);
72
+ * });
73
+ * ```
74
+ */
39
75
  exports.moduleExport = v.object({
40
76
  exportName: v.string(),
41
77
  exportPath: v.string()
@@ -1,3 +1,77 @@
1
+ /**
2
+ * @fileoverview Prettier Configuration System for SKMTC Core
3
+ *
4
+ * This module provides comprehensive type definitions and validation schemas for
5
+ * Prettier code formatting configuration within the SKMTC code generation pipeline.
6
+ * It ensures that generated code is properly formatted according to specified
7
+ * formatting rules and style guidelines.
8
+ *
9
+ * The Prettier configuration system supports all standard Prettier options,
10
+ * enabling fine-tuned control over code formatting for different output targets
11
+ * and project requirements.
12
+ *
13
+ * ## Key Features
14
+ *
15
+ * - **Complete Option Coverage**: All Prettier configuration options supported
16
+ * - **Type Safety**: Full TypeScript typing and Valibot validation
17
+ * - **Flexible Configuration**: Optional settings with sensible defaults
18
+ * - **Multi-Language Support**: Formatting options for JavaScript, TypeScript, JSX, HTML, and more
19
+ * - **Integration Ready**: Direct integration with the SKMTC rendering pipeline
20
+ *
21
+ * @example Basic Prettier configuration
22
+ * ```typescript
23
+ * import type { PrettierConfigType } from '@skmtc/core/PrettierConfig';
24
+ *
25
+ * const config: PrettierConfigType = {
26
+ * printWidth: 100,
27
+ * tabWidth: 2,
28
+ * useTabs: false,
29
+ * semi: true,
30
+ * singleQuote: true,
31
+ * trailingComma: 'es5'
32
+ * };
33
+ * ```
34
+ *
35
+ * @example TypeScript and JSX formatting
36
+ * ```typescript
37
+ * import type { PrettierConfigType } from '@skmtc/core/PrettierConfig';
38
+ *
39
+ * const tsConfig: PrettierConfigType = {
40
+ * printWidth: 120,
41
+ * tabWidth: 2,
42
+ * semi: true,
43
+ * singleQuote: true,
44
+ * jsxSingleQuote: true,
45
+ * bracketSameLine: false,
46
+ * arrowParens: 'avoid'
47
+ * };
48
+ * ```
49
+ *
50
+ * @example Validation usage
51
+ * ```typescript
52
+ * import { prettierConfigType, PrettierConfigType } from '@skmtc/core/PrettierConfig';
53
+ * import * as v from 'valibot';
54
+ *
55
+ * function validatePrettierConfig(config: unknown): PrettierConfigType {
56
+ * return v.parse(prettierConfigType, config);
57
+ * }
58
+ *
59
+ * const userConfig = {
60
+ * printWidth: 80,
61
+ * singleQuote: true,
62
+ * invalidOption: 'test' // This would cause validation error
63
+ * };
64
+ *
65
+ * try {
66
+ * const validConfig = validatePrettierConfig(userConfig);
67
+ * console.log('Valid configuration:', validConfig);
68
+ * } catch (error) {
69
+ * console.error('Invalid Prettier configuration:', error);
70
+ * }
71
+ * ```
72
+ *
73
+ * @module PrettierConfig
74
+ */
1
75
  import "../_dnt.polyfills.js";
2
76
  import * as v from 'valibot';
3
77
  export type PrettierConfigType = {
@@ -1 +1 @@
1
- {"version":3,"file":"PrettierConfig.d.ts","sourceRoot":"","sources":["../../src/types/PrettierConfig.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B,MAAM,MAAM,kBAAkB,GAAG;IAC/B,UAAU,CAAC,EAAE,MA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, "__esModule", { value: true });
36
36
  exports.prettierConfigType = void 0;
37
+ /**
38
+ * @fileoverview Prettier Configuration System for SKMTC Core
39
+ *
40
+ * This module provides comprehensive type definitions and validation schemas for
41
+ * Prettier code formatting configuration within the SKMTC code generation pipeline.
42
+ * It ensures that generated code is properly formatted according to specified
43
+ * formatting rules and style guidelines.
44
+ *
45
+ * The Prettier configuration system supports all standard Prettier options,
46
+ * enabling fine-tuned control over code formatting for different output targets
47
+ * and project requirements.
48
+ *
49
+ * ## Key Features
50
+ *
51
+ * - **Complete Option Coverage**: All Prettier configuration options supported
52
+ * - **Type Safety**: Full TypeScript typing and Valibot validation
53
+ * - **Flexible Configuration**: Optional settings with sensible defaults
54
+ * - **Multi-Language Support**: Formatting options for JavaScript, TypeScript, JSX, HTML, and more
55
+ * - **Integration Ready**: Direct integration with the SKMTC rendering pipeline
56
+ *
57
+ * @example Basic Prettier configuration
58
+ * ```typescript
59
+ * import type { PrettierConfigType } from '@skmtc/core/PrettierConfig';
60
+ *
61
+ * const config: PrettierConfigType = {
62
+ * printWidth: 100,
63
+ * tabWidth: 2,
64
+ * useTabs: false,
65
+ * semi: true,
66
+ * singleQuote: true,
67
+ * trailingComma: 'es5'
68
+ * };
69
+ * ```
70
+ *
71
+ * @example TypeScript and JSX formatting
72
+ * ```typescript
73
+ * import type { PrettierConfigType } from '@skmtc/core/PrettierConfig';
74
+ *
75
+ * const tsConfig: PrettierConfigType = {
76
+ * printWidth: 120,
77
+ * tabWidth: 2,
78
+ * semi: true,
79
+ * singleQuote: true,
80
+ * jsxSingleQuote: true,
81
+ * bracketSameLine: false,
82
+ * arrowParens: 'avoid'
83
+ * };
84
+ * ```
85
+ *
86
+ * @example Validation usage
87
+ * ```typescript
88
+ * import { prettierConfigType, PrettierConfigType } from '@skmtc/core/PrettierConfig';
89
+ * import * as v from 'valibot';
90
+ *
91
+ * function validatePrettierConfig(config: unknown): PrettierConfigType {
92
+ * return v.parse(prettierConfigType, config);
93
+ * }
94
+ *
95
+ * const userConfig = {
96
+ * printWidth: 80,
97
+ * singleQuote: true,
98
+ * invalidOption: 'test' // This would cause validation error
99
+ * };
100
+ *
101
+ * try {
102
+ * const validConfig = validatePrettierConfig(userConfig);
103
+ * console.log('Valid configuration:', validConfig);
104
+ * } catch (error) {
105
+ * console.error('Invalid Prettier configuration:', error);
106
+ * }
107
+ * ```
108
+ *
109
+ * @module PrettierConfig
110
+ */
37
111
  require("../_dnt.polyfills.js");
38
112
  const v = __importStar(require("valibot"));
39
113
  exports.prettierConfigType = v.object({
@@ -1,3 +1,100 @@
1
+ /**
2
+ * @fileoverview Results and Status Tracking System for SKMTC Core
3
+ *
4
+ * This module provides comprehensive result tracking and status management for
5
+ * the SKMTC code generation pipeline. It includes hierarchical result structures,
6
+ * type-safe status definitions, and validation schemas for tracking the outcomes
7
+ * of parsing, generation, and rendering operations.
8
+ *
9
+ * The results system enables detailed reporting and error handling throughout
10
+ * the pipeline, supporting nested result structures for complex operations
11
+ * and comprehensive status categorization.
12
+ *
13
+ * ## Key Features
14
+ *
15
+ * - **Hierarchical Results**: Nested result structures for complex operations
16
+ * - **Status Categories**: Complete coverage of operation outcomes (success, warning, error, etc.)
17
+ * - **Type Safety**: Full TypeScript typing with Valibot validation
18
+ * - **Recursive Support**: Lazy evaluation for deeply nested result structures
19
+ * - **Pipeline Integration**: Direct integration with SKMTC processing contexts
20
+ *
21
+ * @example Basic result tracking
22
+ * ```typescript
23
+ * import type { ResultType, ResultsItem } from '@skmtc/core/Results';
24
+ *
25
+ * const operationResult: ResultType = 'success';
26
+ * const errorResult: ResultType = 'error';
27
+ *
28
+ * const results: ResultsItem = {
29
+ * parsing: 'success',
30
+ * generation: 'warning',
31
+ * rendering: 'success'
32
+ * };
33
+ * ```
34
+ *
35
+ * @example Hierarchical result structures
36
+ * ```typescript
37
+ * import type { ResultsItem } from '@skmtc/core/Results';
38
+ *
39
+ * const complexResults: ResultsItem = {
40
+ * parsing: {
41
+ * schemas: 'success',
42
+ * operations: {
43
+ * userApi: 'success',
44
+ * productApi: 'warning',
45
+ * orderApi: 'error'
46
+ * }
47
+ * },
48
+ * generation: [
49
+ * { models: 'success' },
50
+ * { services: 'warning' },
51
+ * null // Skipped operation
52
+ * ]
53
+ * };
54
+ * ```
55
+ *
56
+ * @example Result validation
57
+ * ```typescript
58
+ * import { resultsItem, resultType, ResultsItem } from '@skmtc/core/Results';
59
+ * import * as v from 'valibot';
60
+ *
61
+ * function validateResults(data: unknown): ResultsItem {
62
+ * return v.parse(resultsItem, data);
63
+ * }
64
+ *
65
+ * function validateResultType(status: unknown): ResultType {
66
+ * return v.parse(resultType, status);
67
+ * }
68
+ *
69
+ * // Usage
70
+ * const results = validateResults({
71
+ * operation: 'success',
72
+ * nested: {
73
+ * subOperation: 'warning'
74
+ * }
75
+ * });
76
+ * ```
77
+ *
78
+ * @example Error filtering
79
+ * ```typescript
80
+ * import type { ResultType, WarningError } from '@skmtc/core/Results';
81
+ *
82
+ * function hasIssues(result: ResultType): result is WarningError {
83
+ * return result === 'warning' || result === 'error';
84
+ * }
85
+ *
86
+ * function processResults(results: Record<string, ResultType>) {
87
+ * const issues = Object.entries(results)
88
+ * .filter(([, status]) => hasIssues(status));
89
+ *
90
+ * if (issues.length > 0) {
91
+ * console.log('Operations with issues:', issues);
92
+ * }
93
+ * }
94
+ * ```
95
+ *
96
+ * @module Results
97
+ */
1
98
  import "../_dnt.polyfills.js";
2
99
  import * as v from 'valibot';
3
100
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"Results.d.ts","sourceRoot":"","sources":["../../src/types/Results.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B;;;;;GAKG;AACH,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,cAAc,CAAA;AAErF;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,CAAA;AAE9C;;;;;GAKG;AACH,eAAO,MAAM,UAAU,EAAE,CAAC,CAAC,aAAa,CAAC,UAAU,CAMjD,CAAA;AAEF;;;;;;GAMG;AACH,MAAM,WAAW,WAAW;IAC1B,+DAA+D;IAC/D,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,GAAG,WAAW,GAAG,KAAK,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;CACpE;AAED;;;;;GAKG;AACH,eAAO,MAAM,WAAW,EAAE,CAAC,CAAC,aAAa,CAAC,WAAW,CAGpD,CAAA"}
1
+ {"version":3,"file":"Results.d.ts","sourceRoot":"","sources":["../../src/types/Results.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgGG;AACH,OAAO,sBAAsB,CAAC;AAG9B,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAE5B;;;;;GAKG;AACH,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,cAAc,CAAA;AAErF;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,CAAA;AAE9C;;;;;GAKG;AACH,eAAO,MAAM,UAAU,EAAE,CAAC,CAAC,aAAa,CAAC,UAAU,CAMjD,CAAA;AAEF;;;;;;GAMG;AACH,MAAM,WAAW,WAAW;IAC1B,+DAA+D;IAC/D,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,GAAG,WAAW,GAAG,KAAK,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;CACpE;AAED;;;;;GAKG;AACH,eAAO,MAAM,WAAW,EAAE,CAAC,CAAC,aAAa,CAAC,WAAW,CAGpD,CAAA"}
@@ -34,6 +34,103 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.resultsItem = exports.resultType = void 0;
37
+ /**
38
+ * @fileoverview Results and Status Tracking System for SKMTC Core
39
+ *
40
+ * This module provides comprehensive result tracking and status management for
41
+ * the SKMTC code generation pipeline. It includes hierarchical result structures,
42
+ * type-safe status definitions, and validation schemas for tracking the outcomes
43
+ * of parsing, generation, and rendering operations.
44
+ *
45
+ * The results system enables detailed reporting and error handling throughout
46
+ * the pipeline, supporting nested result structures for complex operations
47
+ * and comprehensive status categorization.
48
+ *
49
+ * ## Key Features
50
+ *
51
+ * - **Hierarchical Results**: Nested result structures for complex operations
52
+ * - **Status Categories**: Complete coverage of operation outcomes (success, warning, error, etc.)
53
+ * - **Type Safety**: Full TypeScript typing with Valibot validation
54
+ * - **Recursive Support**: Lazy evaluation for deeply nested result structures
55
+ * - **Pipeline Integration**: Direct integration with SKMTC processing contexts
56
+ *
57
+ * @example Basic result tracking
58
+ * ```typescript
59
+ * import type { ResultType, ResultsItem } from '@skmtc/core/Results';
60
+ *
61
+ * const operationResult: ResultType = 'success';
62
+ * const errorResult: ResultType = 'error';
63
+ *
64
+ * const results: ResultsItem = {
65
+ * parsing: 'success',
66
+ * generation: 'warning',
67
+ * rendering: 'success'
68
+ * };
69
+ * ```
70
+ *
71
+ * @example Hierarchical result structures
72
+ * ```typescript
73
+ * import type { ResultsItem } from '@skmtc/core/Results';
74
+ *
75
+ * const complexResults: ResultsItem = {
76
+ * parsing: {
77
+ * schemas: 'success',
78
+ * operations: {
79
+ * userApi: 'success',
80
+ * productApi: 'warning',
81
+ * orderApi: 'error'
82
+ * }
83
+ * },
84
+ * generation: [
85
+ * { models: 'success' },
86
+ * { services: 'warning' },
87
+ * null // Skipped operation
88
+ * ]
89
+ * };
90
+ * ```
91
+ *
92
+ * @example Result validation
93
+ * ```typescript
94
+ * import { resultsItem, resultType, ResultsItem } from '@skmtc/core/Results';
95
+ * import * as v from 'valibot';
96
+ *
97
+ * function validateResults(data: unknown): ResultsItem {
98
+ * return v.parse(resultsItem, data);
99
+ * }
100
+ *
101
+ * function validateResultType(status: unknown): ResultType {
102
+ * return v.parse(resultType, status);
103
+ * }
104
+ *
105
+ * // Usage
106
+ * const results = validateResults({
107
+ * operation: 'success',
108
+ * nested: {
109
+ * subOperation: 'warning'
110
+ * }
111
+ * });
112
+ * ```
113
+ *
114
+ * @example Error filtering
115
+ * ```typescript
116
+ * import type { ResultType, WarningError } from '@skmtc/core/Results';
117
+ *
118
+ * function hasIssues(result: ResultType): result is WarningError {
119
+ * return result === 'warning' || result === 'error';
120
+ * }
121
+ *
122
+ * function processResults(results: Record<string, ResultType>) {
123
+ * const issues = Object.entries(results)
124
+ * .filter(([, status]) => hasIssues(status));
125
+ *
126
+ * if (issues.length > 0) {
127
+ * console.log('Operations with issues:', issues);
128
+ * }
129
+ * }
130
+ * ```
131
+ *
132
+ * @module Results
133
+ */
37
134
  require("../_dnt.polyfills.js");
38
135
  const v = __importStar(require("valibot"));
39
136
  /**