@memberjunction/react-runtime 2.112.0 → 2.113.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +11 -10
- package/CHANGELOG.md +14 -1
- package/dist/compiler/component-compiler.d.ts.map +1 -1
- package/dist/compiler/component-compiler.js +56 -66
- package/dist/compiler/component-compiler.js.map +1 -1
- package/dist/component-manager/component-manager.d.ts.map +1 -1
- package/dist/component-manager/component-manager.js +42 -48
- package/dist/component-manager/component-manager.js.map +1 -1
- package/dist/component-manager/types.d.ts +1 -1
- package/dist/component-manager/types.d.ts.map +1 -1
- package/dist/component-manager/types.js.map +1 -1
- package/dist/registry/component-registry-service.d.ts +1 -1
- package/dist/registry/component-registry-service.d.ts.map +1 -1
- package/dist/registry/component-registry-service.js +34 -34
- package/dist/registry/component-registry-service.js.map +1 -1
- package/dist/registry/component-resolver.d.ts +1 -1
- package/dist/registry/component-resolver.d.ts.map +1 -1
- package/dist/registry/component-resolver.js +11 -10
- package/dist/registry/component-resolver.js.map +1 -1
- package/dist/runtime/component-hierarchy.d.ts +1 -1
- package/dist/runtime/component-hierarchy.d.ts.map +1 -1
- package/dist/runtime/component-hierarchy.js +43 -43
- package/dist/runtime/component-hierarchy.js.map +1 -1
- package/dist/runtime/prop-builder.d.ts.map +1 -1
- package/dist/runtime/prop-builder.js +24 -22
- package/dist/runtime/prop-builder.js.map +1 -1
- package/dist/runtime.umd.js +511 -494
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js.map +1 -1
- package/dist/utilities/library-registry.d.ts +1 -1
- package/dist/utilities/library-registry.d.ts.map +1 -1
- package/dist/utilities/library-registry.js +10 -10
- package/dist/utilities/library-registry.js.map +1 -1
- package/package.json +6 -5
- package/src/compiler/component-compiler.ts +164 -186
- package/src/component-manager/component-manager.ts +216 -162
- package/src/component-manager/types.ts +27 -27
- package/src/registry/component-registry-service.ts +218 -190
- package/src/registry/component-resolver.ts +98 -87
- package/src/runtime/component-hierarchy.ts +94 -57
- package/src/runtime/prop-builder.ts +33 -28
- package/src/types/index.ts +4 -3
- package/src/utilities/library-registry.ts +19 -14
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
import { ComponentSpec } from '@memberjunction/interactive-component-types';
|
|
6
|
-
import { UserInfo } from '@memberjunction/
|
|
6
|
+
import { UserInfo } from '@memberjunction/core';
|
|
7
7
|
import { ComponentLibraryEntity } from '@memberjunction/core-entities';
|
|
8
8
|
import { ComponentObject } from '../types';
|
|
9
9
|
|
|
@@ -20,42 +20,42 @@ export interface LoadOptions {
|
|
|
20
20
|
* User context for database operations and registry fetching
|
|
21
21
|
*/
|
|
22
22
|
contextUser?: UserInfo;
|
|
23
|
-
|
|
23
|
+
|
|
24
24
|
/**
|
|
25
25
|
* Force re-fetch from registry even if cached
|
|
26
26
|
*/
|
|
27
27
|
forceRefresh?: boolean;
|
|
28
|
-
|
|
28
|
+
|
|
29
29
|
/**
|
|
30
30
|
* Force recompilation even if compiled version exists
|
|
31
31
|
*/
|
|
32
32
|
forceRecompile?: boolean;
|
|
33
|
-
|
|
33
|
+
|
|
34
34
|
/**
|
|
35
35
|
* Whether this is a dependent component (for tracking)
|
|
36
36
|
*/
|
|
37
37
|
isDependent?: boolean;
|
|
38
|
-
|
|
38
|
+
|
|
39
39
|
/**
|
|
40
40
|
* What to return from the load operation
|
|
41
41
|
*/
|
|
42
42
|
returnType?: 'component' | 'spec' | 'both';
|
|
43
|
-
|
|
43
|
+
|
|
44
44
|
/**
|
|
45
45
|
* Enable registry usage tracking for licensing (default: true)
|
|
46
46
|
*/
|
|
47
47
|
trackUsage?: boolean;
|
|
48
|
-
|
|
48
|
+
|
|
49
49
|
/**
|
|
50
50
|
* Namespace to use if not specified in spec
|
|
51
51
|
*/
|
|
52
52
|
defaultNamespace?: string;
|
|
53
|
-
|
|
53
|
+
|
|
54
54
|
/**
|
|
55
55
|
* Version to use if not specified in spec
|
|
56
56
|
*/
|
|
57
57
|
defaultVersion?: string;
|
|
58
|
-
|
|
58
|
+
|
|
59
59
|
/**
|
|
60
60
|
* How to format resolved specs:
|
|
61
61
|
* - 'preserve-metadata': Keep registry/namespace/name intact (for UI display)
|
|
@@ -63,7 +63,7 @@ export interface LoadOptions {
|
|
|
63
63
|
* @default 'preserve-metadata'
|
|
64
64
|
*/
|
|
65
65
|
resolutionMode?: ResolutionMode;
|
|
66
|
-
|
|
66
|
+
|
|
67
67
|
/**
|
|
68
68
|
* All available component libraries (for browser context where ComponentMetadataEngine isn't available)
|
|
69
69
|
*/
|
|
@@ -78,22 +78,22 @@ export interface LoadResult {
|
|
|
78
78
|
* Whether the load operation succeeded
|
|
79
79
|
*/
|
|
80
80
|
success: boolean;
|
|
81
|
-
|
|
81
|
+
|
|
82
82
|
/**
|
|
83
83
|
* The compiled component object
|
|
84
84
|
*/
|
|
85
85
|
component?: ComponentObject;
|
|
86
|
-
|
|
86
|
+
|
|
87
87
|
/**
|
|
88
88
|
* The fully resolved component specification
|
|
89
89
|
*/
|
|
90
90
|
spec?: ComponentSpec;
|
|
91
|
-
|
|
91
|
+
|
|
92
92
|
/**
|
|
93
93
|
* Whether the component was loaded from cache
|
|
94
94
|
*/
|
|
95
95
|
fromCache: boolean;
|
|
96
|
-
|
|
96
|
+
|
|
97
97
|
/**
|
|
98
98
|
* Any errors that occurred during loading
|
|
99
99
|
*/
|
|
@@ -102,7 +102,7 @@ export interface LoadResult {
|
|
|
102
102
|
phase: 'fetch' | 'compile' | 'register' | 'dependency';
|
|
103
103
|
componentName?: string;
|
|
104
104
|
}>;
|
|
105
|
-
|
|
105
|
+
|
|
106
106
|
/**
|
|
107
107
|
* Components that were loaded as dependencies
|
|
108
108
|
*/
|
|
@@ -117,22 +117,22 @@ export interface HierarchyResult {
|
|
|
117
117
|
* Whether the entire hierarchy loaded successfully
|
|
118
118
|
*/
|
|
119
119
|
success: boolean;
|
|
120
|
-
|
|
120
|
+
|
|
121
121
|
/**
|
|
122
122
|
* The root component object
|
|
123
123
|
*/
|
|
124
124
|
rootComponent?: ComponentObject;
|
|
125
|
-
|
|
125
|
+
|
|
126
126
|
/**
|
|
127
127
|
* The fully resolved root specification
|
|
128
128
|
*/
|
|
129
129
|
resolvedSpec?: ComponentSpec;
|
|
130
|
-
|
|
130
|
+
|
|
131
131
|
/**
|
|
132
132
|
* List of all component names that were loaded
|
|
133
133
|
*/
|
|
134
134
|
loadedComponents: string[];
|
|
135
|
-
|
|
135
|
+
|
|
136
136
|
/**
|
|
137
137
|
* Any errors that occurred during loading
|
|
138
138
|
*/
|
|
@@ -141,12 +141,12 @@ export interface HierarchyResult {
|
|
|
141
141
|
phase: 'fetch' | 'compile' | 'register' | 'dependency';
|
|
142
142
|
componentName?: string;
|
|
143
143
|
}>;
|
|
144
|
-
|
|
144
|
+
|
|
145
145
|
/**
|
|
146
146
|
* Map of all loaded components by name
|
|
147
147
|
*/
|
|
148
148
|
components?: Record<string, ComponentObject>;
|
|
149
|
-
|
|
149
|
+
|
|
150
150
|
/**
|
|
151
151
|
* Number of components loaded from cache vs fetched
|
|
152
152
|
*/
|
|
@@ -166,27 +166,27 @@ export interface ComponentManagerConfig {
|
|
|
166
166
|
* Enable debug logging
|
|
167
167
|
*/
|
|
168
168
|
debug?: boolean;
|
|
169
|
-
|
|
169
|
+
|
|
170
170
|
/**
|
|
171
171
|
* Maximum cache size for fetched specs
|
|
172
172
|
*/
|
|
173
173
|
maxCacheSize?: number;
|
|
174
|
-
|
|
174
|
+
|
|
175
175
|
/**
|
|
176
176
|
* Cache TTL in milliseconds (default: 1 hour)
|
|
177
177
|
*/
|
|
178
178
|
cacheTTL?: number;
|
|
179
|
-
|
|
179
|
+
|
|
180
180
|
/**
|
|
181
181
|
* Whether to track registry usage for licensing
|
|
182
182
|
*/
|
|
183
183
|
enableUsageTracking?: boolean;
|
|
184
|
-
|
|
184
|
+
|
|
185
185
|
/**
|
|
186
186
|
* Batch size for parallel dependency loading
|
|
187
187
|
*/
|
|
188
188
|
dependencyBatchSize?: number;
|
|
189
|
-
|
|
189
|
+
|
|
190
190
|
/**
|
|
191
191
|
* Timeout for registry fetch operations (ms)
|
|
192
192
|
*/
|
|
@@ -201,4 +201,4 @@ export interface CacheEntry {
|
|
|
201
201
|
fetchedAt: Date;
|
|
202
202
|
hash?: string;
|
|
203
203
|
usageNotified: boolean;
|
|
204
|
-
}
|
|
204
|
+
}
|