@preference-sl/prefconfigurator-wasm 2.0.0 → 2.0.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/_framework/{PrefConfigurator.Abstractions.1yznk6sqco.wasm → PrefConfigurator.Abstractions.xc84eo304b.wasm} +0 -0
- package/_framework/PrefConfigurator.Abstractions.xc84eo304b.wasm.br +0 -0
- package/_framework/{PrefConfigurator.Abstractions.1yznk6sqco.wasm.gz → PrefConfigurator.Abstractions.xc84eo304b.wasm.gz} +0 -0
- package/_framework/{PrefConfigurator.Application.lr3i5lxos0.wasm → PrefConfigurator.Application.2v52eoz0eq.wasm} +0 -0
- package/_framework/PrefConfigurator.Application.2v52eoz0eq.wasm.br +0 -0
- package/_framework/{PrefConfigurator.Application.lr3i5lxos0.wasm.gz → PrefConfigurator.Application.2v52eoz0eq.wasm.gz} +0 -0
- package/_framework/{PrefConfigurator.Infrastructure.0259fp5kaj.wasm → PrefConfigurator.Infrastructure.0t4d0ld2oi.wasm} +0 -0
- package/_framework/PrefConfigurator.Infrastructure.0t4d0ld2oi.wasm.br +0 -0
- package/_framework/PrefConfigurator.Infrastructure.0t4d0ld2oi.wasm.gz +0 -0
- package/_framework/PrefConfigurator.Wasm.h671nae0lt.wasm +0 -0
- package/_framework/PrefConfigurator.Wasm.h671nae0lt.wasm.br +0 -0
- package/_framework/PrefConfigurator.Wasm.h671nae0lt.wasm.gz +0 -0
- package/_framework/blazor.boot.json +9 -9
- package/_framework/blazor.boot.json.br +0 -0
- package/_framework/blazor.boot.json.gz +0 -0
- package/js/prefconfigurator-api.d.ts +127 -4
- package/package.json +1 -1
- package/_framework/PrefConfigurator.Abstractions.1yznk6sqco.wasm.br +0 -0
- package/_framework/PrefConfigurator.Application.lr3i5lxos0.wasm.br +0 -0
- package/_framework/PrefConfigurator.Infrastructure.0259fp5kaj.wasm.br +0 -0
- package/_framework/PrefConfigurator.Infrastructure.0259fp5kaj.wasm.gz +0 -0
- package/_framework/PrefConfigurator.Wasm.pxmidb5bkr.wasm +0 -0
- package/_framework/PrefConfigurator.Wasm.pxmidb5bkr.wasm.br +0 -0
- package/_framework/PrefConfigurator.Wasm.pxmidb5bkr.wasm.gz +0 -0
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"mainAssemblyName": "PrefConfigurator.Wasm",
|
|
3
3
|
"resources": {
|
|
4
|
-
"hash": "sha256-
|
|
4
|
+
"hash": "sha256-XZR/9iIs2EF5abBhv3FhEBTYweKAvgdEyrUU4oOXB7o=",
|
|
5
5
|
"fingerprinting": {
|
|
6
6
|
"Microsoft.CSharp.soa7iupusj.wasm": "Microsoft.CSharp.wasm",
|
|
7
7
|
"Microsoft.Extensions.Caching.Abstractions.9tfokavdri.wasm": "Microsoft.Extensions.Caching.Abstractions.wasm",
|
|
@@ -34,10 +34,10 @@
|
|
|
34
34
|
"Microsoft.Extensions.Options.bzdoshyjeq.wasm": "Microsoft.Extensions.Options.wasm",
|
|
35
35
|
"Microsoft.Extensions.Primitives.ii8zcoqmmf.wasm": "Microsoft.Extensions.Primitives.wasm",
|
|
36
36
|
"Newtonsoft.Json.ou6h2ikg0u.wasm": "Newtonsoft.Json.wasm",
|
|
37
|
-
"PrefConfigurator.Abstractions.
|
|
38
|
-
"PrefConfigurator.Application.
|
|
39
|
-
"PrefConfigurator.Infrastructure.
|
|
40
|
-
"PrefConfigurator.Wasm.
|
|
37
|
+
"PrefConfigurator.Abstractions.xc84eo304b.wasm": "PrefConfigurator.Abstractions.wasm",
|
|
38
|
+
"PrefConfigurator.Application.2v52eoz0eq.wasm": "PrefConfigurator.Application.wasm",
|
|
39
|
+
"PrefConfigurator.Infrastructure.0t4d0ld2oi.wasm": "PrefConfigurator.Infrastructure.wasm",
|
|
40
|
+
"PrefConfigurator.Wasm.h671nae0lt.wasm": "PrefConfigurator.Wasm.wasm",
|
|
41
41
|
"Preference.Hydra.OpenApi.oba396x8m7.wasm": "Preference.Hydra.OpenApi.wasm",
|
|
42
42
|
"System.Collections.Concurrent.kq7l3koqtq.wasm": "System.Collections.Concurrent.wasm",
|
|
43
43
|
"System.Collections.NonGeneric.u4veqqwbpo.wasm": "System.Collections.NonGeneric.wasm",
|
|
@@ -134,10 +134,10 @@
|
|
|
134
134
|
"Microsoft.Extensions.Options.bzdoshyjeq.wasm": "sha256-OUMXYxUKhNC6l0LAh4xpi+gy+X9b0XXW3pZh9YdZ9C8=",
|
|
135
135
|
"Microsoft.Extensions.Primitives.ii8zcoqmmf.wasm": "sha256-Jt5QBSXSDEahiZ89Pn1MhJ9A3C/ftN8ZXaBGV9JgqwQ=",
|
|
136
136
|
"Newtonsoft.Json.ou6h2ikg0u.wasm": "sha256-8EZ4H5Mb5yxuavrUzuw5k75ewxJQbdU+Y1rksETqPVo=",
|
|
137
|
-
"PrefConfigurator.Abstractions.
|
|
138
|
-
"PrefConfigurator.Application.
|
|
139
|
-
"PrefConfigurator.Infrastructure.
|
|
140
|
-
"PrefConfigurator.Wasm.
|
|
137
|
+
"PrefConfigurator.Abstractions.xc84eo304b.wasm": "sha256-UWF2E8C0vCVR49dIFoFuNFOp6Wbma7+z2i7ETamMPsI=",
|
|
138
|
+
"PrefConfigurator.Application.2v52eoz0eq.wasm": "sha256-Luhs4HHos5BcNx0W2KmaYPv3LwZYRxbXz7cbjnXJAKw=",
|
|
139
|
+
"PrefConfigurator.Infrastructure.0t4d0ld2oi.wasm": "sha256-lB2ZRV7M5O0pg29eNSOQWu/eWxx4YwoQhM0LdtsUT+M=",
|
|
140
|
+
"PrefConfigurator.Wasm.h671nae0lt.wasm": "sha256-Z2ZLbC64WybaFX/wisWPPO+VKWW9V5t+b4t/p3o4rVo=",
|
|
141
141
|
"Preference.Hydra.OpenApi.oba396x8m7.wasm": "sha256-BOitG9XqTGoVdagU40GvNefDuOylKCPs3Gp5VG0M3oY=",
|
|
142
142
|
"System.Collections.Concurrent.kq7l3koqtq.wasm": "sha256-lDJetX8MOCPfYgq+j+JjNEwEFA9oW7BLaaNmAFUZQaE=",
|
|
143
143
|
"System.Collections.NonGeneric.u4veqqwbpo.wasm": "sha256-Hlfxail2eLYOSROomwSdgZ3zfxPgxeQCs+6AiZn4uBE=",
|
|
Binary file
|
|
Binary file
|
|
@@ -89,16 +89,19 @@ export interface SetOptionValueResponse {
|
|
|
89
89
|
message?: string | null;
|
|
90
90
|
optionChanged?: boolean | null;
|
|
91
91
|
}
|
|
92
|
+
|
|
92
93
|
export interface SetOptionValueRequest {
|
|
93
94
|
optionName: string;
|
|
94
95
|
optionValue: string;
|
|
95
96
|
}
|
|
97
|
+
|
|
96
98
|
export interface SetOptionValueBatchResult {
|
|
97
99
|
optionName: string;
|
|
98
100
|
sent: boolean;
|
|
99
101
|
reason?: string | null;
|
|
100
102
|
response?: SetOptionValueResponse | null;
|
|
101
103
|
}
|
|
104
|
+
|
|
102
105
|
export interface SetOptionsResponse {
|
|
103
106
|
requestedCount: number;
|
|
104
107
|
sentCount: number;
|
|
@@ -155,6 +158,98 @@ export interface Scene {
|
|
|
155
158
|
WallDatas: SceneWallData[];
|
|
156
159
|
}
|
|
157
160
|
|
|
161
|
+
export interface EnvJson {
|
|
162
|
+
version?: number | null;
|
|
163
|
+
|
|
164
|
+
services: {
|
|
165
|
+
baseUrl: string;
|
|
166
|
+
hydraBaseUrl?: string | null;
|
|
167
|
+
prefWebBaseUrl?: string | null;
|
|
168
|
+
kbApiBaseUrl?: string | null;
|
|
169
|
+
cloudPrefWebBaseUrl?: string | null;
|
|
170
|
+
kbUiBaseUrl?: string | null;
|
|
171
|
+
wallGeneratorBaseUrl?: string | null;
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
maker: {
|
|
175
|
+
name?: string | null;
|
|
176
|
+
prefix?: string | null;
|
|
177
|
+
};
|
|
178
|
+
|
|
179
|
+
ui: {
|
|
180
|
+
definitionName?: string | null;
|
|
181
|
+
optionListName?: string | null;
|
|
182
|
+
};
|
|
183
|
+
|
|
184
|
+
auth: {
|
|
185
|
+
username?: string | null;
|
|
186
|
+
password?: string | null;
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
images: {
|
|
190
|
+
model: {
|
|
191
|
+
onlyModelImage: boolean;
|
|
192
|
+
type2D: number;
|
|
193
|
+
type3D: number;
|
|
194
|
+
width: number;
|
|
195
|
+
height: number;
|
|
196
|
+
daysToLive: number;
|
|
197
|
+
};
|
|
198
|
+
scene: {
|
|
199
|
+
name: string;
|
|
200
|
+
format: string;
|
|
201
|
+
};
|
|
202
|
+
materials: {
|
|
203
|
+
daysToLive: number;
|
|
204
|
+
};
|
|
205
|
+
};
|
|
206
|
+
|
|
207
|
+
storage: {
|
|
208
|
+
gltf: {
|
|
209
|
+
dbName: string;
|
|
210
|
+
storeName: string;
|
|
211
|
+
};
|
|
212
|
+
};
|
|
213
|
+
|
|
214
|
+
runtime: {
|
|
215
|
+
logLevel: string;
|
|
216
|
+
};
|
|
217
|
+
|
|
218
|
+
flags?: Record<string, boolean> | null;
|
|
219
|
+
extra?: Record<string, any | null> | null;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
export enum ViewMode {
|
|
223
|
+
_0, _1, _2, _3
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
export enum ImageType {
|
|
227
|
+
_0, _1, _2, _3, _4, _5, _6, _7, _8, _9,
|
|
228
|
+
_10, _11, _12, _13, _14, _15, _16, _17
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export interface CadRendererData {
|
|
232
|
+
viewMode: ViewMode;
|
|
233
|
+
cameraProjection?: number | null;
|
|
234
|
+
cameraPosition?: number | null;
|
|
235
|
+
predefinedView?: string | null;
|
|
236
|
+
backgroundColor?: number | null;
|
|
237
|
+
customProperties?: string | null;
|
|
238
|
+
texturesRootPath?: string | null;
|
|
239
|
+
base64Textures?: boolean | null;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
export interface ModelImageConfig {
|
|
243
|
+
imageType: ImageType;
|
|
244
|
+
width: number;
|
|
245
|
+
height: number;
|
|
246
|
+
units: number;
|
|
247
|
+
usePrefOne: boolean;
|
|
248
|
+
languageId: number;
|
|
249
|
+
visualPropertiesXML?: string | null;
|
|
250
|
+
cadRenderer?: CadRendererData | null;
|
|
251
|
+
}
|
|
252
|
+
|
|
158
253
|
export interface JsInteropApiRaw {
|
|
159
254
|
InitializeFromEnvJson(json: string): void;
|
|
160
255
|
GetOptions<T = EnhancedOptionList>(): Promise<OperationResult<T> | string>;
|
|
@@ -162,7 +257,7 @@ export interface JsInteropApiRaw {
|
|
|
162
257
|
CreateItem<T = CreateItemResponse>(modelCode: string, isPersistable: boolean): Promise<OperationResult<T> | string>;
|
|
163
258
|
GetDimensions<T = DimensionsResponse>(modelId: string): Promise<OperationResult<T> | string>;
|
|
164
259
|
SetDimensions<T = SetDimensionsResponse>(modelId: string, dimensionName: string, dimensionValue: number): Promise<OperationResult<T> | string>;
|
|
165
|
-
SetOptions<T = SetOptionsResponse>(modelId: string,
|
|
260
|
+
SetOptions<T = SetOptionsResponse>(modelId: string, optionsJson: string): Promise<OperationResult<T> | string>;
|
|
166
261
|
GetModelOptions<T = OptionInfo[]>(modelId: string): Promise<OperationResult<T> | string>;
|
|
167
262
|
GetScene<T = Scene>(sceneName?: string, sceneFormat?: string, texturesRootPath?: string): Promise<OperationResult<T> | string>;
|
|
168
263
|
GetModelImage(modelId: string, modelImageConfigJson: string, sceneName?: string): Promise<OperationResult<string> | string>;
|
|
@@ -186,11 +281,39 @@ export function ensureOk<T = JsonValue>(raw: RawOperation<T>): T;
|
|
|
186
281
|
|
|
187
282
|
type AwaitedReturn<T> = T extends Promise<infer R> ? R : T;
|
|
188
283
|
type ExtractData<R> = AwaitedReturn<R> extends OperationResult<infer D> ? D : JsonValue;
|
|
189
|
-
|
|
284
|
+
|
|
285
|
+
type BoundMethod<F> =
|
|
286
|
+
F extends (...args: infer A) => Promise<infer R>
|
|
190
287
|
? (...args: A) => Promise<ExtractData<R>>
|
|
191
288
|
: F;
|
|
192
|
-
|
|
193
|
-
|
|
289
|
+
|
|
290
|
+
//
|
|
291
|
+
// BOUND API � PUBLIC API CORRECTLY TYPED
|
|
292
|
+
//
|
|
293
|
+
|
|
294
|
+
export type BoundApi<TRaw extends JsInteropApiRaw> = {
|
|
295
|
+
[K in keyof TRaw]: TRaw[K] extends Function
|
|
296
|
+
? BoundMethod<TRaw[K]>
|
|
297
|
+
: TRaw[K];
|
|
298
|
+
} & {
|
|
299
|
+
|
|
300
|
+
InitializeFromEnvJson(config: EnvJson): void;
|
|
301
|
+
|
|
302
|
+
UpdateOptions(
|
|
303
|
+
optionList: OptionList,
|
|
304
|
+
changedOptionName: string
|
|
305
|
+
): Promise<EnhancedOptionList>;
|
|
306
|
+
|
|
307
|
+
SetOptions(
|
|
308
|
+
modelId: string,
|
|
309
|
+
updates: SetOptionValueRequest[]
|
|
310
|
+
): Promise<SetOptionsResponse>;
|
|
311
|
+
|
|
312
|
+
GetModelImage(
|
|
313
|
+
modelId: string,
|
|
314
|
+
config: ModelImageConfig,
|
|
315
|
+
sceneName?: string
|
|
316
|
+
): Promise<string>;
|
|
194
317
|
};
|
|
195
318
|
|
|
196
319
|
export function bindApi<TRaw extends JsInteropApiRaw>(rawApi: TRaw): BoundApi<TRaw>;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"postinstall": "node scripts/postinstall.js"
|
|
4
4
|
},
|
|
5
5
|
"description": ".NET WebAssembly runtime package that centralizes logic for building product configurators, exposing a simple API for integration into ecommerce platforms.",
|
|
6
|
-
"version": "2.0.
|
|
6
|
+
"version": "2.0.1",
|
|
7
7
|
"files": [
|
|
8
8
|
"_framework/**",
|
|
9
9
|
"**/*.js",
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|