@salesforce/metadata-core-sdk 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (150) hide show
  1. package/LICENSE.txt +27 -0
  2. package/README.md +219 -0
  3. package/dist/index.d.ts +38 -0
  4. package/dist/index.d.ts.map +1 -0
  5. package/dist/index.js +22 -0
  6. package/dist/index.js.map +1 -0
  7. package/dist/sdk/abstractions/core/IPlatformContext.d.ts +45 -0
  8. package/dist/sdk/abstractions/core/IPlatformContext.d.ts.map +1 -0
  9. package/dist/sdk/abstractions/core/IPlatformContext.js +8 -0
  10. package/dist/sdk/abstractions/core/IPlatformContext.js.map +1 -0
  11. package/dist/sdk/abstractions/core/index.d.ts +8 -0
  12. package/dist/sdk/abstractions/core/index.d.ts.map +1 -0
  13. package/dist/sdk/abstractions/core/index.js +8 -0
  14. package/dist/sdk/abstractions/core/index.js.map +1 -0
  15. package/dist/sdk/abstractions/index.d.ts +17 -0
  16. package/dist/sdk/abstractions/index.d.ts.map +1 -0
  17. package/dist/sdk/abstractions/index.js +20 -0
  18. package/dist/sdk/abstractions/index.js.map +1 -0
  19. package/dist/sdk/abstractions/services/IFileSystem.d.ts +114 -0
  20. package/dist/sdk/abstractions/services/IFileSystem.d.ts.map +1 -0
  21. package/dist/sdk/abstractions/services/IFileSystem.js +8 -0
  22. package/dist/sdk/abstractions/services/IFileSystem.js.map +1 -0
  23. package/dist/sdk/abstractions/services/ILogger.d.ts +63 -0
  24. package/dist/sdk/abstractions/services/ILogger.d.ts.map +1 -0
  25. package/dist/sdk/abstractions/services/ILogger.js +18 -0
  26. package/dist/sdk/abstractions/services/ILogger.js.map +1 -0
  27. package/dist/sdk/abstractions/services/ITelemetry.d.ts +159 -0
  28. package/dist/sdk/abstractions/services/ITelemetry.d.ts.map +1 -0
  29. package/dist/sdk/abstractions/services/ITelemetry.js +97 -0
  30. package/dist/sdk/abstractions/services/ITelemetry.js.map +1 -0
  31. package/dist/sdk/abstractions/services/index.d.ts +10 -0
  32. package/dist/sdk/abstractions/services/index.d.ts.map +1 -0
  33. package/dist/sdk/abstractions/services/index.js +10 -0
  34. package/dist/sdk/abstractions/services/index.js.map +1 -0
  35. package/dist/sdk/abstractions/types/FileMetadata.d.ts +15 -0
  36. package/dist/sdk/abstractions/types/FileMetadata.d.ts.map +1 -0
  37. package/dist/sdk/abstractions/types/FileMetadata.js +8 -0
  38. package/dist/sdk/abstractions/types/FileMetadata.js.map +1 -0
  39. package/dist/sdk/abstractions/types/Result.d.ts +15 -0
  40. package/dist/sdk/abstractions/types/Result.d.ts.map +1 -0
  41. package/dist/sdk/abstractions/types/Result.js +8 -0
  42. package/dist/sdk/abstractions/types/Result.js.map +1 -0
  43. package/dist/sdk/abstractions/types/index.d.ts +9 -0
  44. package/dist/sdk/abstractions/types/index.d.ts.map +1 -0
  45. package/dist/sdk/abstractions/types/index.js +9 -0
  46. package/dist/sdk/abstractions/types/index.js.map +1 -0
  47. package/dist/sdk/constants.d.ts +35 -0
  48. package/dist/sdk/constants.d.ts.map +1 -0
  49. package/dist/sdk/constants.js +35 -0
  50. package/dist/sdk/constants.js.map +1 -0
  51. package/dist/sdk/contracts/core/IMetadataParser.d.ts +49 -0
  52. package/dist/sdk/contracts/core/IMetadataParser.d.ts.map +1 -0
  53. package/dist/sdk/contracts/core/IMetadataParser.js +8 -0
  54. package/dist/sdk/contracts/core/IMetadataParser.js.map +1 -0
  55. package/dist/sdk/contracts/core/IVisualizationPlugin.d.ts +65 -0
  56. package/dist/sdk/contracts/core/IVisualizationPlugin.d.ts.map +1 -0
  57. package/dist/sdk/contracts/core/IVisualizationPlugin.js +8 -0
  58. package/dist/sdk/contracts/core/IVisualizationPlugin.js.map +1 -0
  59. package/dist/sdk/contracts/core/index.d.ts +9 -0
  60. package/dist/sdk/contracts/core/index.d.ts.map +1 -0
  61. package/dist/sdk/contracts/core/index.js +9 -0
  62. package/dist/sdk/contracts/core/index.js.map +1 -0
  63. package/dist/sdk/contracts/index.d.ts +9 -0
  64. package/dist/sdk/contracts/index.d.ts.map +1 -0
  65. package/dist/sdk/contracts/index.js +9 -0
  66. package/dist/sdk/contracts/index.js.map +1 -0
  67. package/dist/sdk/contracts/types/MetadataPluginInfo.d.ts +56 -0
  68. package/dist/sdk/contracts/types/MetadataPluginInfo.d.ts.map +1 -0
  69. package/dist/sdk/contracts/types/MetadataPluginInfo.js +8 -0
  70. package/dist/sdk/contracts/types/MetadataPluginInfo.js.map +1 -0
  71. package/dist/sdk/contracts/types/PluginConfig.d.ts +16 -0
  72. package/dist/sdk/contracts/types/PluginConfig.d.ts.map +1 -0
  73. package/dist/sdk/contracts/types/PluginConfig.js +8 -0
  74. package/dist/sdk/contracts/types/PluginConfig.js.map +1 -0
  75. package/dist/sdk/contracts/types/PluginContext.d.ts +22 -0
  76. package/dist/sdk/contracts/types/PluginContext.d.ts.map +1 -0
  77. package/dist/sdk/contracts/types/PluginContext.js +8 -0
  78. package/dist/sdk/contracts/types/PluginContext.js.map +1 -0
  79. package/dist/sdk/contracts/types/PluginError.d.ts +50 -0
  80. package/dist/sdk/contracts/types/PluginError.d.ts.map +1 -0
  81. package/dist/sdk/contracts/types/PluginError.js +31 -0
  82. package/dist/sdk/contracts/types/PluginError.js.map +1 -0
  83. package/dist/sdk/contracts/types/ValidationResult.d.ts +15 -0
  84. package/dist/sdk/contracts/types/ValidationResult.d.ts.map +1 -0
  85. package/dist/sdk/contracts/types/ValidationResult.js +8 -0
  86. package/dist/sdk/contracts/types/ValidationResult.js.map +1 -0
  87. package/dist/sdk/contracts/types/VersionInfo.d.ts +24 -0
  88. package/dist/sdk/contracts/types/VersionInfo.d.ts.map +1 -0
  89. package/dist/sdk/contracts/types/VersionInfo.js +8 -0
  90. package/dist/sdk/contracts/types/VersionInfo.js.map +1 -0
  91. package/dist/sdk/contracts/types/index.d.ts +13 -0
  92. package/dist/sdk/contracts/types/index.d.ts.map +1 -0
  93. package/dist/sdk/contracts/types/index.js +13 -0
  94. package/dist/sdk/contracts/types/index.js.map +1 -0
  95. package/dist/sdk/design-system/index.d.ts +11 -0
  96. package/dist/sdk/design-system/index.d.ts.map +1 -0
  97. package/dist/sdk/design-system/index.js +12 -0
  98. package/dist/sdk/design-system/index.js.map +1 -0
  99. package/dist/sdk/design-system/tokens/colors.d.ts +122 -0
  100. package/dist/sdk/design-system/tokens/colors.d.ts.map +1 -0
  101. package/dist/sdk/design-system/tokens/colors.js +142 -0
  102. package/dist/sdk/design-system/tokens/colors.js.map +1 -0
  103. package/dist/sdk/design-system/tokens/spacing.d.ts +24 -0
  104. package/dist/sdk/design-system/tokens/spacing.d.ts.map +1 -0
  105. package/dist/sdk/design-system/tokens/spacing.js +24 -0
  106. package/dist/sdk/design-system/tokens/spacing.js.map +1 -0
  107. package/dist/sdk/design-system/tokens/typography.d.ts +31 -0
  108. package/dist/sdk/design-system/tokens/typography.d.ts.map +1 -0
  109. package/dist/sdk/design-system/tokens/typography.js +31 -0
  110. package/dist/sdk/design-system/tokens/typography.js.map +1 -0
  111. package/dist/sdk/design-system/utils.d.ts +66 -0
  112. package/dist/sdk/design-system/utils.d.ts.map +1 -0
  113. package/dist/sdk/design-system/utils.js +116 -0
  114. package/dist/sdk/design-system/utils.js.map +1 -0
  115. package/dist/sdk/design-system/vscode-design-system.css +623 -0
  116. package/dist/sdk/utils/errors/ErrorBoundary.d.ts +35 -0
  117. package/dist/sdk/utils/errors/ErrorBoundary.d.ts.map +1 -0
  118. package/dist/sdk/utils/errors/ErrorBoundary.js +65 -0
  119. package/dist/sdk/utils/errors/ErrorBoundary.js.map +1 -0
  120. package/dist/sdk/utils/errors/ErrorBuilder.d.ts +107 -0
  121. package/dist/sdk/utils/errors/ErrorBuilder.d.ts.map +1 -0
  122. package/dist/sdk/utils/errors/ErrorBuilder.js +163 -0
  123. package/dist/sdk/utils/errors/ErrorBuilder.js.map +1 -0
  124. package/dist/sdk/utils/errors/setupHandlers.d.ts +12 -0
  125. package/dist/sdk/utils/errors/setupHandlers.d.ts.map +1 -0
  126. package/dist/sdk/utils/errors/setupHandlers.js +42 -0
  127. package/dist/sdk/utils/errors/setupHandlers.js.map +1 -0
  128. package/dist/sdk/utils/logger.d.ts +41 -0
  129. package/dist/sdk/utils/logger.d.ts.map +1 -0
  130. package/dist/sdk/utils/logger.js +54 -0
  131. package/dist/sdk/utils/logger.js.map +1 -0
  132. package/dist/sdk/utils/test-helpers/architecture-test-utils.d.ts +146 -0
  133. package/dist/sdk/utils/test-helpers/architecture-test-utils.d.ts.map +1 -0
  134. package/dist/sdk/utils/test-helpers/architecture-test-utils.js +286 -0
  135. package/dist/sdk/utils/test-helpers/architecture-test-utils.js.map +1 -0
  136. package/dist/sdk/utils/test-helpers/index.d.ts +8 -0
  137. package/dist/sdk/utils/test-helpers/index.d.ts.map +1 -0
  138. package/dist/sdk/utils/test-helpers/index.js +8 -0
  139. package/dist/sdk/utils/test-helpers/index.js.map +1 -0
  140. package/dist/sdk/utils/xmlParser.d.ts +38 -0
  141. package/dist/sdk/utils/xmlParser.d.ts.map +1 -0
  142. package/dist/sdk/utils/xmlParser.js +79 -0
  143. package/dist/sdk/utils/xmlParser.js.map +1 -0
  144. package/dist/sdk/webviewMessageTypes.d.ts +24 -0
  145. package/dist/sdk/webviewMessageTypes.d.ts.map +1 -0
  146. package/dist/sdk/webviewMessageTypes.js +23 -0
  147. package/dist/sdk/webviewMessageTypes.js.map +1 -0
  148. package/package.json +80 -0
  149. package/src/sdk/utils/test-helpers/architecture-test-utils.ts +365 -0
  150. package/src/sdk/utils/test-helpers/index.ts +20 -0
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export * from './IVisualizationPlugin.js';
8
+ export * from './IMetadataParser.js';
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/core/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,cAAc,2BAA2B,CAAC;AAC1C,cAAc,sBAAsB,CAAC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export * from './IVisualizationPlugin.js';
8
+ export * from './IMetadataParser.js';
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/core/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,cAAc,2BAA2B,CAAC;AAC1C,cAAc,sBAAsB,CAAC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export * from './core/index.js';
8
+ export * from './types/index.js';
9
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/sdk/contracts/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export * from './core/index.js';
8
+ export * from './types/index.js';
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/sdk/contracts/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ /**
8
+ * Plugin metadata information
9
+ *
10
+ * Contains identifying and descriptive information about a plugin.
11
+ */
12
+ export interface MetadataPluginInfo {
13
+ /**
14
+ * Unique identifier for the plugin.
15
+ * Must match the plugin folder name (e.g., 'object' for plugins/object/, 'flow' for plugins/flow/).
16
+ */
17
+ id: string;
18
+ /** Display name */
19
+ name: string;
20
+ /** Description */
21
+ description?: string;
22
+ /** Team/author */
23
+ author: string;
24
+ /** File patterns this plugin handles */
25
+ filePatterns: string[];
26
+ /**
27
+ * Priority for plugin selection when multiple plugins can handle the same file
28
+ * Higher values = higher priority
29
+ * Default: 0
30
+ */
31
+ priority?: number;
32
+ /**
33
+ * Trusted external sources for CSP directives.
34
+ * Allows plugins to declare CDN sources needed for external scripts, styles, or network requests.
35
+ *
36
+ * Security: Only HTTPS URLs are permitted. Non-HTTPS sources are filtered out.
37
+ *
38
+ * Example usage (Flow/Object plugins loading Mermaid from CDN):
39
+ * ```typescript
40
+ * trustedSources: {
41
+ * scripts: ['https://cdn.jsdelivr.net'], // Allows: document.createElement('script').src = 'https://cdn.jsdelivr.net/npm/mermaid@10/...'
42
+ * }
43
+ * ```
44
+ *
45
+ * Plugins without trustedSources get strict CSP with no external script/network access.
46
+ */
47
+ trustedSources?: {
48
+ /** HTTPS URLs to add to CSP script-src directive (e.g., 'https://cdn.jsdelivr.net') */
49
+ scripts?: string[];
50
+ /** HTTPS URLs to add to CSP style-src directive (e.g., 'https://fonts.googleapis.com') */
51
+ styles?: string[];
52
+ /** HTTPS URLs to add to CSP connect-src directive (e.g., 'https://api.example.com') */
53
+ connect?: string[];
54
+ };
55
+ }
56
+ //# sourceMappingURL=MetadataPluginInfo.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MetadataPluginInfo.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/MetadataPluginInfo.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ;;;;GAIG;AACH,MAAM,WAAW,kBAAkB;IACjC;;;OAGG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAC;IAEb,kBAAkB;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,kBAAkB;IAClB,MAAM,EAAE,MAAM,CAAC;IAEf,wCAAwC;IACxC,YAAY,EAAE,MAAM,EAAE,CAAC;IAEvB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;;;;;;;;;;;;;OAcG;IACH,cAAc,CAAC,EAAE;QACf,uFAAuF;QACvF,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;QACnB,0FAA0F;QAC1F,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;QAClB,uFAAuF;QACvF,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;KACpB,CAAC;CACH"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export {};
8
+ //# sourceMappingURL=MetadataPluginInfo.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MetadataPluginInfo.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/MetadataPluginInfo.ts"],"names":[],"mappings":"AAAA;;;;;IAKI"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ /**
8
+ * Platform-agnostic configuration for plugin loading.
9
+ *
10
+ * Used by both the plugins repo and the framework to pass
11
+ * user settings (e.g., feature flags).
12
+ */
13
+ export interface PluginConfig {
14
+ pluginSettings?: Record<string, unknown>;
15
+ }
16
+ //# sourceMappingURL=PluginConfig.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PluginConfig.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/PluginConfig.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC1C"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export {};
8
+ //# sourceMappingURL=PluginConfig.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PluginConfig.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/PluginConfig.ts"],"names":[],"mappings":"AAAA;;;;;IAKI"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ import { ILogger } from '../../abstractions/services/ILogger.js';
8
+ import { IFileSystem } from '../../abstractions/services/IFileSystem.js';
9
+ /**
10
+ * Platform-agnostic context provided to plugins during rendering
11
+ */
12
+ export interface PluginContext {
13
+ /** Current file path (absolute) */
14
+ filePath: string;
15
+ /** File name (without path) */
16
+ fileName: string;
17
+ /** Logger instance */
18
+ logger: ILogger;
19
+ /** File system operations */
20
+ fileSystem: IFileSystem;
21
+ }
22
+ //# sourceMappingURL=PluginContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PluginContext.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/PluginContext.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,OAAO,EAAE,OAAO,EAAE,MAAM,wCAAwC,CAAC;AACjE,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AAEzE;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,mCAAmC;IACnC,QAAQ,EAAE,MAAM,CAAC;IAEjB,+BAA+B;IAC/B,QAAQ,EAAE,MAAM,CAAC;IAEjB,sBAAsB;IACtB,MAAM,EAAE,OAAO,CAAC;IAEhB,6BAA6B;IAC7B,UAAU,EAAE,WAAW,CAAC;CACzB"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export {};
8
+ //# sourceMappingURL=PluginContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PluginContext.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/PluginContext.ts"],"names":[],"mappings":"AAAA;;;;;IAKI"}
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ /**
8
+ * Categories of runtime errors that can occur during visualization
9
+ */
10
+ export declare enum ErrorCategory {
11
+ /** Errors during metadata file parsing (e.g., invalid XML, malformed structure) */
12
+ Parsing = "Parsing",
13
+ /** Errors during metadata validation (e.g., missing required fields, invalid values) */
14
+ Validation = "Validation",
15
+ /** Network-related errors (e.g., CDN failures, external resource loading) */
16
+ Network = "Network",
17
+ /** Missing or invalid dependencies (e.g., parent object not found, related files missing) */
18
+ Dependency = "Dependency",
19
+ /** Errors during visualization rendering (e.g., React component crashes, diagram generation failures) */
20
+ Rendering = "Rendering",
21
+ /** Operations that exceed time limits */
22
+ Timeout = "Timeout",
23
+ /** File system permission or access errors */
24
+ Permission = "Permission",
25
+ /** Invalid plugin or framework configuration */
26
+ Configuration = "Configuration",
27
+ /** Uncategorized or generic errors */
28
+ Runtime = "Runtime"
29
+ }
30
+ /**
31
+ * Structured error object for plugin and framework errors
32
+ *
33
+ * This interface defines the contract for all errors reported by plugins
34
+ * and the framework during visualization operations.
35
+ */
36
+ export interface PluginError {
37
+ /** Category of the error */
38
+ category: ErrorCategory;
39
+ /** Human-readable error message (short and descriptive) */
40
+ message: string;
41
+ /** Full stack trace or detailed error information (optional) */
42
+ stackTrace?: string;
43
+ /** Additional context data (e.g., field names, file paths, metadata) */
44
+ context?: Record<string, any>;
45
+ /** Plugin ID (auto-populated by framework) */
46
+ pluginId?: string;
47
+ /** File path being visualized (auto-populated by framework) */
48
+ filePath?: string;
49
+ }
50
+ //# sourceMappingURL=PluginError.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PluginError.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/PluginError.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ;;GAEG;AACH,oBAAY,aAAa;IACvB,mFAAmF;IACnF,OAAO,YAAY;IAEnB,wFAAwF;IACxF,UAAU,eAAe;IAEzB,6EAA6E;IAC7E,OAAO,YAAY;IAEnB,6FAA6F;IAC7F,UAAU,eAAe;IAEzB,yGAAyG;IACzG,SAAS,cAAc;IAEvB,yCAAyC;IACzC,OAAO,YAAY;IAEnB,8CAA8C;IAC9C,UAAU,eAAe;IAEzB,gDAAgD;IAChD,aAAa,kBAAkB;IAE/B,sCAAsC;IACtC,OAAO,YAAY;CACpB;AAED;;;;;GAKG;AACH,MAAM,WAAW,WAAW;IAC1B,4BAA4B;IAC5B,QAAQ,EAAE,aAAa,CAAC;IAExB,2DAA2D;IAC3D,OAAO,EAAE,MAAM,CAAC;IAEhB,gEAAgE;IAChE,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,wEAAwE;IACxE,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAE9B,8CAA8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ /**
8
+ * Categories of runtime errors that can occur during visualization
9
+ */
10
+ export var ErrorCategory;
11
+ (function (ErrorCategory) {
12
+ /** Errors during metadata file parsing (e.g., invalid XML, malformed structure) */
13
+ ErrorCategory["Parsing"] = "Parsing";
14
+ /** Errors during metadata validation (e.g., missing required fields, invalid values) */
15
+ ErrorCategory["Validation"] = "Validation";
16
+ /** Network-related errors (e.g., CDN failures, external resource loading) */
17
+ ErrorCategory["Network"] = "Network";
18
+ /** Missing or invalid dependencies (e.g., parent object not found, related files missing) */
19
+ ErrorCategory["Dependency"] = "Dependency";
20
+ /** Errors during visualization rendering (e.g., React component crashes, diagram generation failures) */
21
+ ErrorCategory["Rendering"] = "Rendering";
22
+ /** Operations that exceed time limits */
23
+ ErrorCategory["Timeout"] = "Timeout";
24
+ /** File system permission or access errors */
25
+ ErrorCategory["Permission"] = "Permission";
26
+ /** Invalid plugin or framework configuration */
27
+ ErrorCategory["Configuration"] = "Configuration";
28
+ /** Uncategorized or generic errors */
29
+ ErrorCategory["Runtime"] = "Runtime";
30
+ })(ErrorCategory || (ErrorCategory = {}));
31
+ //# sourceMappingURL=PluginError.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PluginError.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/PluginError.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ;;GAEG;AACH,MAAM,CAAN,IAAY,aA2BX;AA3BD,WAAY,aAAa;IACvB,mFAAmF;IACnF,oCAAmB,CAAA;IAEnB,wFAAwF;IACxF,0CAAyB,CAAA;IAEzB,6EAA6E;IAC7E,oCAAmB,CAAA;IAEnB,6FAA6F;IAC7F,0CAAyB,CAAA;IAEzB,yGAAyG;IACzG,wCAAuB,CAAA;IAEvB,yCAAyC;IACzC,oCAAmB,CAAA;IAEnB,8CAA8C;IAC9C,0CAAyB,CAAA;IAEzB,gDAAgD;IAChD,gDAA+B,CAAA;IAE/B,sCAAsC;IACtC,oCAAmB,CAAA;AACrB,CAAC,EA3BW,aAAa,KAAb,aAAa,QA2BxB"}
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ /**
8
+ * Result of validation
9
+ */
10
+ export interface ValidationResult {
11
+ valid: boolean;
12
+ errors: string[];
13
+ warnings: string[];
14
+ }
15
+ //# sourceMappingURL=ValidationResult.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ValidationResult.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/ValidationResult.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export {};
8
+ //# sourceMappingURL=ValidationResult.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ValidationResult.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/ValidationResult.ts"],"names":[],"mappings":"AAAA;;;;;IAKI"}
@@ -0,0 +1,24 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ /**
8
+ * Version information collected by framework
9
+ *
10
+ * This type represents API version sources that the framework collects
11
+ * from project-level configuration files. Individual parsers decide which
12
+ * version to use and can also extract file-level versions themselves.
13
+ */
14
+ export interface VersionInfo {
15
+ /**
16
+ * API version from package.xml <version> tag (if present)
17
+ */
18
+ packageVersion?: string;
19
+ /**
20
+ * API version from sfdx-project.json sourceApiVersion (if present)
21
+ */
22
+ sourceApiVersion?: string;
23
+ }
24
+ //# sourceMappingURL=VersionInfo.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VersionInfo.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/VersionInfo.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ;;;;;;GAMG;AACH,MAAM,WAAW,WAAW;IAC1B;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export {};
8
+ //# sourceMappingURL=VersionInfo.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VersionInfo.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/VersionInfo.ts"],"names":[],"mappings":"AAAA;;;;;IAKI"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export * from './MetadataPluginInfo.js';
8
+ export * from './ValidationResult.js';
9
+ export * from './PluginContext.js';
10
+ export * from './VersionInfo.js';
11
+ export * from './PluginError.js';
12
+ export * from './PluginConfig.js';
13
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export * from './MetadataPluginInfo.js';
8
+ export * from './ValidationResult.js';
9
+ export * from './PluginContext.js';
10
+ export * from './VersionInfo.js';
11
+ export * from './PluginError.js';
12
+ export * from './PluginConfig.js';
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/sdk/contracts/types/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export { colorTokens, shadowTokens } from './tokens/colors.js';
8
+ export { spacingTokens, borderRadiusTokens } from './tokens/spacing.js';
9
+ export { fontFamilyTokens, fontSizeTokens, fontWeightTokens, lineHeightTokens, } from './tokens/typography.js';
10
+ export { getCSSVariableValue, getCSSVariableValues, resolveTokens, cssVar } from './utils.js';
11
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/sdk/design-system/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AACxE,OAAO,EACL,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,gBAAgB,GACjB,MAAM,wBAAwB,CAAC;AAGhC,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC"}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export { colorTokens, shadowTokens } from './tokens/colors.js';
8
+ export { spacingTokens, borderRadiusTokens } from './tokens/spacing.js';
9
+ export { fontFamilyTokens, fontSizeTokens, fontWeightTokens, lineHeightTokens, } from './tokens/typography.js';
10
+ // Runtime utilities for resolving design tokens to actual values
11
+ export { getCSSVariableValue, getCSSVariableValues, resolveTokens, cssVar } from './utils.js';
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/sdk/design-system/index.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AACxE,OAAO,EACL,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,gBAAgB,GACjB,MAAM,wBAAwB,CAAC;AAEhC,iEAAiE;AACjE,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC"}
@@ -0,0 +1,122 @@
1
+ /**
2
+ * Copyright (c) 2025, Salesforce, Inc.
3
+ * All rights reserved.
4
+ * Licensed under the BSD 3-Clause license.
5
+ * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
+ **/
7
+ export declare const colorTokens: {
8
+ readonly canvas: {
9
+ readonly bg: "--mv-canvas-bg";
10
+ readonly grid: "--mv-canvas-grid";
11
+ readonly minimapBg: "--mv-minimap-bg";
12
+ };
13
+ readonly panel: {
14
+ readonly bg: "--mv-panel-bg";
15
+ readonly border: "--mv-panel-border";
16
+ readonly shadow: "--mv-panel-shadow";
17
+ };
18
+ readonly node: {
19
+ readonly bg: "--mv-node-bg";
20
+ readonly border: "--mv-node-border";
21
+ readonly bgHover: "--mv-node-bg-hover";
22
+ readonly bgSelected: "--mv-node-bg-selected";
23
+ readonly fg: "--mv-node-fg";
24
+ readonly fgSecondary: "--mv-node-fg-secondary";
25
+ };
26
+ readonly edge: {
27
+ readonly neutral: "--mv-edge-neutral";
28
+ readonly active: "--mv-edge-active";
29
+ };
30
+ readonly functionalAccents: {
31
+ readonly data: "--mv-accent-data";
32
+ readonly logic: "--mv-accent-logic";
33
+ readonly ui: "--mv-accent-ui";
34
+ readonly system: "--mv-accent-system";
35
+ };
36
+ readonly stateIndicators: {
37
+ readonly positive: "--mv-status-positive";
38
+ readonly negative: "--mv-status-negative";
39
+ readonly warning: "--mv-status-warning";
40
+ readonly info: "--mv-status-info";
41
+ readonly neutral: "--mv-status-neutral";
42
+ };
43
+ readonly marker: {
44
+ readonly primary: "--mv-marker-primary";
45
+ readonly muted: "--mv-marker-muted";
46
+ };
47
+ readonly separator: "--mv-separator";
48
+ readonly regionZone: "--mv-region-zone";
49
+ readonly highContrast: {
50
+ readonly border: "--mv-hc-border";
51
+ readonly selection: "--mv-hc-selection";
52
+ };
53
+ readonly backgrounds: {
54
+ readonly primary: "--mv-bg-primary";
55
+ readonly secondary: "--mv-bg-secondary";
56
+ readonly elevated: "--mv-bg-elevated";
57
+ readonly surface: "--mv-bg-surface";
58
+ readonly surfaceHover: "--mv-bg-surface-hover";
59
+ readonly input: "--mv-bg-input";
60
+ readonly overlay: "--mv-bg-overlay";
61
+ };
62
+ readonly text: {
63
+ readonly primary: "--mv-text-primary";
64
+ readonly secondary: "--mv-text-secondary";
65
+ readonly muted: "--mv-text-muted";
66
+ readonly inverse: "--mv-text-inverse";
67
+ };
68
+ readonly interactive: {
69
+ readonly primary: "--mv-interactive-primary";
70
+ readonly primaryHover: "--mv-interactive-primary-hover";
71
+ readonly secondary: "--mv-interactive-secondary";
72
+ readonly focus: "--mv-interactive-focus";
73
+ readonly focusBorder: "--mv-interactive-focus-border";
74
+ };
75
+ readonly button: {
76
+ readonly primaryBg: "--mv-button-primary-bg";
77
+ readonly primaryFg: "--mv-button-primary-fg";
78
+ readonly secondaryBg: "--mv-button-secondary-bg";
79
+ readonly secondaryFg: "--mv-button-secondary-fg";
80
+ };
81
+ readonly borders: {
82
+ readonly default: "--mv-border-default";
83
+ readonly primary: "--mv-border-primary";
84
+ readonly hover: "--mv-border-hover";
85
+ readonly input: "--mv-border-input";
86
+ readonly focus: "--mv-border-focus";
87
+ readonly dropdown: "--mv-border-dropdown";
88
+ };
89
+ readonly status: {
90
+ readonly error: "--mv-status-error";
91
+ readonly errorBg: "--mv-status-error-bg";
92
+ readonly errorBorder: "--mv-status-error-border";
93
+ readonly warning: "--mv-status-warning";
94
+ readonly warningBg: "--mv-status-warning-bg";
95
+ readonly warningBorder: "--mv-status-warning-border";
96
+ readonly success: "--mv-status-success";
97
+ readonly info: "--mv-status-info";
98
+ readonly infoBg: "--mv-status-info-bg";
99
+ readonly infoBorder: "--mv-status-info-border";
100
+ };
101
+ readonly accents: {
102
+ readonly cyan: "--mv-accent-cyan";
103
+ readonly cyanLight: "--mv-accent-cyan-light";
104
+ readonly yellow: "--mv-accent-yellow";
105
+ };
106
+ readonly shadows: {
107
+ readonly light: "--mv-shadow-light";
108
+ readonly medium: "--mv-shadow-medium";
109
+ readonly heavy: "--mv-shadow-heavy";
110
+ readonly text: "--mv-shadow-text";
111
+ };
112
+ };
113
+ /**
114
+ * CSS shadow utilities
115
+ */
116
+ export declare const shadowTokens: {
117
+ readonly sm: "--mv-shadow-sm";
118
+ readonly md: "--mv-shadow-md";
119
+ readonly lg: "--mv-shadow-lg";
120
+ readonly xl: "--mv-shadow-xl";
121
+ };
122
+ //# sourceMappingURL=colors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"colors.d.ts","sourceRoot":"","sources":["../../../../src/sdk/design-system/tokens/colors.ts"],"names":[],"mappings":"AAAA;;;;;IAKI;AAEJ,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgJd,CAAC;AAEX;;GAEG;AACH,eAAO,MAAM,YAAY;;;;;CAKf,CAAC"}