@3dsource/metabox-front-api 0.0.16 → 0.0.17

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/README.md CHANGED
@@ -45,8 +45,7 @@ Insert this code into your HTML file just before the closing `</body>` tag:
45
45
 
46
46
  ```html
47
47
  <script type="module">
48
- import { integrateMetaBox, SetEnvironment, SetEnvironmentMaterial, SetMaterial, SetProduct, ShowEmbeddedMenu, GetFastRender, GetPdf, saveImage, FromMetaboxApiAction } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest';
49
- import { ShowOverlayInterface } from './ShowOverlayInterface';
48
+ import { integrateMetaBox, SetEnvironment, ShowOverlayInterface, SetEnvironmentMaterial, SetMaterial, SetProduct, ShowEmbeddedMenu, GetFastRender, GetPdf, saveImage, FromMetaboxApiAction } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest';
50
49
  // Expose API
51
50
  window.env3DSource = { ...window.env3DSource };
52
51
  window.env3DSource.apiReady = (api) => {
@@ -15,7 +15,7 @@ export type MimeType = 'image/png' | 'image/jpeg' | 'image/webp';
15
15
  * **Important**: Invoking this action will buffer it until the viewport is ready. Only then will the request be processed.
16
16
  *
17
17
  * @example
18
- * import { GetFastRender,saveImage } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
18
+ * import { GetFastRender,saveImage } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
19
19
  * window.env3DSource.apiReady = (api) => {
20
20
  * // Listen for events from the MetaBox API
21
21
  * api.addEventListener('metaboxData', (data) => {
@@ -10,7 +10,7 @@ import { ApiAction } from './ApiAction';
10
10
  * **Important**: Invoking this action will buffer it until the viewport is ready. Only then will the request be processed.
11
11
  *
12
12
  * @example
13
- * import { GetPdf } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
13
+ * import { GetPdf } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
14
14
  * window.env3DSource.apiReady = (api) => {
15
15
  * new GetPdf();
16
16
  * };
@@ -7,7 +7,7 @@ import { ApiAction } from './ApiAction';
7
7
  * This action sends a message to the MetaBox API to load the environment level using the specified environment ID.
8
8
  *
9
9
  * @example
10
- * import { SetEnvironment } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
10
+ * import { SetEnvironment } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
11
11
  * window.env3DSource.apiReady = (api) => {
12
12
  * // Change the environment to '55555555-1234-1234-1234-01234567890'
13
13
  * new SetEnvironment('55555555-1234-1234-1234-01234567890');
@@ -8,7 +8,7 @@ import { ApiAction } from './ApiAction';
8
8
  * This action sends a message to the MetaBox API to update the material on a specific environment slot using the provided identifiers.
9
9
  *
10
10
  * @example
11
- * import { SetEnvironmentMaterial } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
11
+ * import { SetEnvironmentMaterial } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
12
12
  * window.env3DSource.apiReady = (api) => {
13
13
  * new SetEnvironmentMaterial(
14
14
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3',
@@ -8,7 +8,7 @@ import { ApiAction } from './ApiAction';
8
8
  * This action sends a message to the MetaBox API to update the material on a specific product slot using the provided identifiers.
9
9
  *
10
10
  * @example
11
- * import { SetMaterial } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
11
+ * import { SetMaterial } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
12
12
  * window.env3DSource.apiReady = (api) => {
13
13
  * new SetMaterial(
14
14
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3',
@@ -8,7 +8,7 @@ import { ApiAction } from './ApiAction';
8
8
  * This action sends a message to the MetaBox API to set a product using the provided product ID.
9
9
  *
10
10
  * @example
11
- * import { SetProduct } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
11
+ * import { SetProduct } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
12
12
  * window.env3DSource.apiReady = (api) => {
13
13
  * new SetProduct(
14
14
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3'
@@ -8,7 +8,7 @@ import { ApiAction } from './ApiAction';
8
8
  * This action sends a message to the MetaBox API to toggle the visibility of the embedded menu.
9
9
  *
10
10
  * @example
11
- * import { ShowEmbeddedMenu } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
11
+ * import { ShowEmbeddedMenu } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
12
12
  * window.env3DSource.apiReady = (api) => {
13
13
  * new ShowEmbeddedMenu(true);
14
14
  * };
@@ -8,7 +8,7 @@ import { ApiAction } from './ApiAction';
8
8
  * This action sends a message to the MetaBox API to toggle the visibility of the Unreal overlay UI.
9
9
  *
10
10
  * @example
11
- * import { ShowOverlayInterface } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
11
+ * import { ShowOverlayInterface } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
12
12
  * window.env3DSource.apiReady = (api) => {
13
13
  * new ShowOverlayInterface(true);
14
14
  * };
package/dist/index.esm.js CHANGED
@@ -1,8 +1,3 @@
1
- /*
2
- * Copyright (c) 2025.
3
- * 3DSource.com, Sergii Karanda steve@3dsource.com
4
- * All Rights Reserved
5
- */
6
1
  /**
7
2
  * To integrate the MetaBox configurator into an HTML element, use the following example:
8
3
  *
@@ -31,11 +26,6 @@ class ApiAction {
31
26
  }
32
27
  }
33
28
 
34
- /*
35
- * Copyright (c) 2025.
36
- * 3DSource.com, Sergii Karanda steve@3dsource.com
37
- * All Rights Reserved
38
- */
39
29
  const ToMetaBoxApiAction = {
40
30
  getPdf: 'getPdf',
41
31
  loadLevel: 'loadLevel',
@@ -56,11 +46,6 @@ const ToMetaBoxApiAction = {
56
46
  setEnvironmentMaterialById: 'setEnvironmentMaterialById',
57
47
  };
58
48
 
59
- /*
60
- * Copyright (c) 2025.
61
- * 3DSource.com, Sergii Karanda steve@3dsource.com
62
- * All Rights Reserved
63
- */
64
49
  /**
65
50
  * {@inheritDoc ApiAction}
66
51
  *
@@ -70,7 +55,7 @@ const ToMetaBoxApiAction = {
70
55
  * This action sends a message to the MetaBox API to toggle the visibility of the Unreal overlay UI.
71
56
  *
72
57
  * @example
73
- * import { ShowOverlayInterface } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
58
+ * import { ShowOverlayInterface } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
74
59
  * window.env3DSource.apiReady = (api) => {
75
60
  * new ShowOverlayInterface(true);
76
61
  * };
@@ -92,11 +77,6 @@ class ShowOverlayInterface extends ApiAction {
92
77
  }
93
78
  }
94
79
 
95
- /*
96
- * Copyright (c) 2025.
97
- * 3DSource.com, Sergii Karanda steve@3dsource.com
98
- * All Rights Reserved
99
- */
100
80
  /**
101
81
  * {@inheritDoc ApiAction}
102
82
  *
@@ -106,7 +86,7 @@ class ShowOverlayInterface extends ApiAction {
106
86
  * This action sends a message to the MetaBox API to toggle the visibility of the embedded menu.
107
87
  *
108
88
  * @example
109
- * import { ShowEmbeddedMenu } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
89
+ * import { ShowEmbeddedMenu } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
110
90
  * window.env3DSource.apiReady = (api) => {
111
91
  * new ShowEmbeddedMenu(true);
112
92
  * };
@@ -128,11 +108,6 @@ class ShowEmbeddedMenu extends ApiAction {
128
108
  }
129
109
  }
130
110
 
131
- /*
132
- * Copyright (c) 2025.
133
- * 3DSource.com, Sergii Karanda steve@3dsource.com
134
- * All Rights Reserved
135
- */
136
111
  /**
137
112
  * {@inheritDoc ApiAction}
138
113
  *
@@ -141,7 +116,7 @@ class ShowEmbeddedMenu extends ApiAction {
141
116
  * This action sends a message to the MetaBox API to load the environment level using the specified environment ID.
142
117
  *
143
118
  * @example
144
- * import { SetEnvironment } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
119
+ * import { SetEnvironment } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
145
120
  * window.env3DSource.apiReady = (api) => {
146
121
  * // Change the environment to '55555555-1234-1234-1234-01234567890'
147
122
  * new SetEnvironment('55555555-1234-1234-1234-01234567890');
@@ -164,11 +139,6 @@ class SetEnvironment extends ApiAction {
164
139
  }
165
140
  }
166
141
 
167
- /*
168
- * Copyright (c) 2025.
169
- * 3DSource.com, Sergii Karanda steve@3dsource.com
170
- * All Rights Reserved
171
- */
172
142
  /**
173
143
  * {@inheritDoc ApiAction}
174
144
  *
@@ -178,7 +148,7 @@ class SetEnvironment extends ApiAction {
178
148
  * This action sends a message to the MetaBox API to set a product using the provided product ID.
179
149
  *
180
150
  * @example
181
- * import { SetProduct } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
151
+ * import { SetProduct } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
182
152
  * window.env3DSource.apiReady = (api) => {
183
153
  * new SetProduct(
184
154
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3'
@@ -202,11 +172,6 @@ class SetProduct extends ApiAction {
202
172
  }
203
173
  }
204
174
 
205
- /*
206
- * Copyright (c) 2025.
207
- * 3DSource.com, Sergii Karanda steve@3dsource.com
208
- * All Rights Reserved
209
- */
210
175
  /**
211
176
  * {@inheritDoc ApiAction}
212
177
  *
@@ -218,7 +183,7 @@ class SetProduct extends ApiAction {
218
183
  * **Important**: Invoking this action will buffer it until the viewport is ready. Only then will the request be processed.
219
184
  *
220
185
  * @example
221
- * import { GetPdf } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
186
+ * import { GetPdf } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
222
187
  * window.env3DSource.apiReady = (api) => {
223
188
  * new GetPdf();
224
189
  * };
@@ -238,11 +203,6 @@ class GetPdf extends ApiAction {
238
203
  }
239
204
  }
240
205
 
241
- /*
242
- * Copyright (c) 2025.
243
- * 3DSource.com, Sergii Karanda steve@3dsource.com
244
- * All Rights Reserved
245
- */
246
206
  /**
247
207
  * {@inheritDoc ApiAction}
248
208
  *
@@ -252,7 +212,7 @@ class GetPdf extends ApiAction {
252
212
  * This action sends a message to the MetaBox API to update the material on a specific product slot using the provided identifiers.
253
213
  *
254
214
  * @example
255
- * import { SetMaterial } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
215
+ * import { SetMaterial } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
256
216
  * window.env3DSource.apiReady = (api) => {
257
217
  * new SetMaterial(
258
218
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3',
@@ -282,11 +242,6 @@ class SetMaterial extends ApiAction {
282
242
  }
283
243
  }
284
244
 
285
- /*
286
- * Copyright (c) 2025.
287
- * 3DSource.com, Sergii Karanda steve@3dsource.com
288
- * All Rights Reserved
289
- */
290
245
  /**
291
246
  * {@inheritDoc ApiAction}
292
247
  *
@@ -296,7 +251,7 @@ class SetMaterial extends ApiAction {
296
251
  * This action sends a message to the MetaBox API to update the material on a specific environment slot using the provided identifiers.
297
252
  *
298
253
  * @example
299
- * import { SetEnvironmentMaterial } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
254
+ * import { SetEnvironmentMaterial } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
300
255
  * window.env3DSource.apiReady = (api) => {
301
256
  * new SetEnvironmentMaterial(
302
257
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3',
@@ -326,11 +281,6 @@ class SetEnvironmentMaterial extends ApiAction {
326
281
  }
327
282
  }
328
283
 
329
- /*
330
- * Copyright (c) 2025.
331
- * 3DSource.com, Sergii Karanda steve@3dsource.com
332
- * All Rights Reserved
333
- */
334
284
  /**
335
285
  * {@inheritDoc ApiAction}
336
286
  *
@@ -341,7 +291,7 @@ class SetEnvironmentMaterial extends ApiAction {
341
291
  * **Important**: Invoking this action will buffer it until the viewport is ready. Only then will the request be processed.
342
292
  *
343
293
  * @example
344
- * import { GetFastRender,saveImage } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
294
+ * import { GetFastRender,saveImage } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
345
295
  * window.env3DSource.apiReady = (api) => {
346
296
  * // Listen for events from the MetaBox API
347
297
  * api.addEventListener('metaboxData', (data) => {
@@ -371,11 +321,6 @@ class GetFastRender extends ApiAction {
371
321
  }
372
322
  }
373
323
 
374
- /*
375
- * Copyright (c) 2025.
376
- * 3DSource.com, Sergii Karanda steve@3dsource.com
377
- * All Rights Reserved
378
- */
379
324
  /**
380
325
  * {@inheritDoc ApiAction}
381
326
  * @internal
@@ -392,11 +337,6 @@ class SendCommandToUnreal extends ApiAction {
392
337
  }
393
338
  }
394
339
 
395
- /*
396
- * Copyright (c) 2025.
397
- * 3DSource.com, Sergii Karanda steve@3dsource.com
398
- * All Rights Reserved
399
- */
400
340
  /**
401
341
  * @experimental
402
342
  * @internal
@@ -420,11 +360,6 @@ class WatchCallbacks extends ApiAction {
420
360
  }
421
361
  }
422
362
 
423
- /*
424
- * Copyright (c) 2025.
425
- * 3DSource.com, Sergii Karanda steve@3dsource.com
426
- * All Rights Reserved
427
- */
428
363
  /**
429
364
  * EventDispatcher is a class that manages event listeners and dispatches events to them.
430
365
  */
@@ -469,11 +404,6 @@ class EventDispatcher {
469
404
  }
470
405
  }
471
406
 
472
- /*
473
- * Copyright (c) 2025.
474
- * 3DSource.com, Sergii Karanda steve@3dsource.com
475
- * All Rights Reserved
476
- */
477
407
  const binderMessageType = 'metaboxData';
478
408
  /**
479
409
  * API class to handle communication with the embedded content.
@@ -568,11 +498,6 @@ class Communicator extends EventDispatcher {
568
498
  */
569
499
  Communicator.instance = null;
570
500
 
571
- /*
572
- * Copyright (c) 2025.
573
- * 3DSource.com, Sergii Karanda steve@3dsource.com
574
- * All Rights Reserved
575
- */
576
501
  /**
577
502
  * Integrates the MetaBox into the provided layout.
578
503
  *
@@ -595,7 +520,7 @@ Communicator.instance = null;
595
520
  * @example
596
521
  * import {
597
522
  * integrateMetaBox,
598
- * } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
523
+ * } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
599
524
  *
600
525
  * integrateMetaBox(
601
526
  * 'https://metabox.3dsource.com/metabox-configurator/basic/12345678-1234-1234-1234-01234567890?introImage=https://example.com/intro.webp&sidebar=false',
@@ -629,11 +554,6 @@ function integrateMetaBox(iframeSrc, containerId = 'embed3DSource') {
629
554
  container.appendChild(iframe);
630
555
  }
631
556
 
632
- /*
633
- * Copyright (c) 2025.
634
- * 3DSource.com, Sergii Karanda steve@3dsource.com
635
- * All Rights Reserved
636
- */
637
557
  /**
638
558
  * Saves an image by triggering a download.
639
559
  *
@@ -653,11 +573,6 @@ function saveImage(image, filename) {
653
573
  document.body.removeChild(a);
654
574
  }
655
575
 
656
- /*
657
- * Copyright (c) 2025.
658
- * 3DSource.com, Sergii Karanda steve@3dsource.com
659
- * All Rights Reserved
660
- */
661
576
  /**
662
577
  * Pauses execution for a specified duration.
663
578
  *
@@ -671,11 +586,6 @@ function sleep(time) {
671
586
  return new Promise((resolve) => setTimeout(resolve, time));
672
587
  }
673
588
 
674
- /*
675
- * Copyright (c) 2025.
676
- * 3DSource.com, Sergii Karanda steve@3dsource.com
677
- * All Rights Reserved
678
- */
679
589
  /**
680
590
  * Sets the URL parameters based on the provided state.
681
591
  *
@@ -709,11 +619,6 @@ function getUrlParams() {
709
619
  return selections;
710
620
  }
711
621
 
712
- /*
713
- * Copyright (c) 2025.
714
- * 3DSource.com, Sergii Karanda steve@3dsource.com
715
- * All Rights Reserved
716
- */
717
622
  const FromMetaboxApiAction = {
718
623
  bridge: 'bridge',
719
624
  appLoaded: 'appLoaded',
@@ -770,11 +675,6 @@ const FromMetaboxApiAction = {
770
675
  getFastRender: 'getFastRender',
771
676
  };
772
677
 
773
- /*
774
- * Copyright (c) 2025.
775
- * 3DSource.com, Sergii Karanda steve@3dsource.com
776
- * All Rights Reserved
777
- */
778
678
  const APPLICATION_DEVICE_TYPES = {
779
679
  deviceTypeAuto: 'deviceTypeAuto',
780
680
  deviceTypeMobile: 'deviceTypeMobile',
@@ -1 +1 @@
1
- {"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/dist/index.umd.js CHANGED
@@ -4,11 +4,6 @@
4
4
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["metabox-front-api"] = {}));
5
5
  })(this, (function (exports) { 'use strict';
6
6
 
7
- /*
8
- * Copyright (c) 2025.
9
- * 3DSource.com, Sergii Karanda steve@3dsource.com
10
- * All Rights Reserved
11
- */
12
7
  /**
13
8
  * To integrate the MetaBox configurator into an HTML element, use the following example:
14
9
  *
@@ -37,11 +32,6 @@
37
32
  }
38
33
  }
39
34
 
40
- /*
41
- * Copyright (c) 2025.
42
- * 3DSource.com, Sergii Karanda steve@3dsource.com
43
- * All Rights Reserved
44
- */
45
35
  const ToMetaBoxApiAction = {
46
36
  getPdf: 'getPdf',
47
37
  loadLevel: 'loadLevel',
@@ -62,11 +52,6 @@
62
52
  setEnvironmentMaterialById: 'setEnvironmentMaterialById',
63
53
  };
64
54
 
65
- /*
66
- * Copyright (c) 2025.
67
- * 3DSource.com, Sergii Karanda steve@3dsource.com
68
- * All Rights Reserved
69
- */
70
55
  /**
71
56
  * {@inheritDoc ApiAction}
72
57
  *
@@ -76,7 +61,7 @@
76
61
  * This action sends a message to the MetaBox API to toggle the visibility of the Unreal overlay UI.
77
62
  *
78
63
  * @example
79
- * import { ShowOverlayInterface } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
64
+ * import { ShowOverlayInterface } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
80
65
  * window.env3DSource.apiReady = (api) => {
81
66
  * new ShowOverlayInterface(true);
82
67
  * };
@@ -98,11 +83,6 @@
98
83
  }
99
84
  }
100
85
 
101
- /*
102
- * Copyright (c) 2025.
103
- * 3DSource.com, Sergii Karanda steve@3dsource.com
104
- * All Rights Reserved
105
- */
106
86
  /**
107
87
  * {@inheritDoc ApiAction}
108
88
  *
@@ -112,7 +92,7 @@
112
92
  * This action sends a message to the MetaBox API to toggle the visibility of the embedded menu.
113
93
  *
114
94
  * @example
115
- * import { ShowEmbeddedMenu } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
95
+ * import { ShowEmbeddedMenu } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
116
96
  * window.env3DSource.apiReady = (api) => {
117
97
  * new ShowEmbeddedMenu(true);
118
98
  * };
@@ -134,11 +114,6 @@
134
114
  }
135
115
  }
136
116
 
137
- /*
138
- * Copyright (c) 2025.
139
- * 3DSource.com, Sergii Karanda steve@3dsource.com
140
- * All Rights Reserved
141
- */
142
117
  /**
143
118
  * {@inheritDoc ApiAction}
144
119
  *
@@ -147,7 +122,7 @@
147
122
  * This action sends a message to the MetaBox API to load the environment level using the specified environment ID.
148
123
  *
149
124
  * @example
150
- * import { SetEnvironment } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
125
+ * import { SetEnvironment } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
151
126
  * window.env3DSource.apiReady = (api) => {
152
127
  * // Change the environment to '55555555-1234-1234-1234-01234567890'
153
128
  * new SetEnvironment('55555555-1234-1234-1234-01234567890');
@@ -170,11 +145,6 @@
170
145
  }
171
146
  }
172
147
 
173
- /*
174
- * Copyright (c) 2025.
175
- * 3DSource.com, Sergii Karanda steve@3dsource.com
176
- * All Rights Reserved
177
- */
178
148
  /**
179
149
  * {@inheritDoc ApiAction}
180
150
  *
@@ -184,7 +154,7 @@
184
154
  * This action sends a message to the MetaBox API to set a product using the provided product ID.
185
155
  *
186
156
  * @example
187
- * import { SetProduct } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
157
+ * import { SetProduct } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
188
158
  * window.env3DSource.apiReady = (api) => {
189
159
  * new SetProduct(
190
160
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3'
@@ -208,11 +178,6 @@
208
178
  }
209
179
  }
210
180
 
211
- /*
212
- * Copyright (c) 2025.
213
- * 3DSource.com, Sergii Karanda steve@3dsource.com
214
- * All Rights Reserved
215
- */
216
181
  /**
217
182
  * {@inheritDoc ApiAction}
218
183
  *
@@ -224,7 +189,7 @@
224
189
  * **Important**: Invoking this action will buffer it until the viewport is ready. Only then will the request be processed.
225
190
  *
226
191
  * @example
227
- * import { GetPdf } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
192
+ * import { GetPdf } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
228
193
  * window.env3DSource.apiReady = (api) => {
229
194
  * new GetPdf();
230
195
  * };
@@ -244,11 +209,6 @@
244
209
  }
245
210
  }
246
211
 
247
- /*
248
- * Copyright (c) 2025.
249
- * 3DSource.com, Sergii Karanda steve@3dsource.com
250
- * All Rights Reserved
251
- */
252
212
  /**
253
213
  * {@inheritDoc ApiAction}
254
214
  *
@@ -258,7 +218,7 @@
258
218
  * This action sends a message to the MetaBox API to update the material on a specific product slot using the provided identifiers.
259
219
  *
260
220
  * @example
261
- * import { SetMaterial } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
221
+ * import { SetMaterial } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
262
222
  * window.env3DSource.apiReady = (api) => {
263
223
  * new SetMaterial(
264
224
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3',
@@ -288,11 +248,6 @@
288
248
  }
289
249
  }
290
250
 
291
- /*
292
- * Copyright (c) 2025.
293
- * 3DSource.com, Sergii Karanda steve@3dsource.com
294
- * All Rights Reserved
295
- */
296
251
  /**
297
252
  * {@inheritDoc ApiAction}
298
253
  *
@@ -302,7 +257,7 @@
302
257
  * This action sends a message to the MetaBox API to update the material on a specific environment slot using the provided identifiers.
303
258
  *
304
259
  * @example
305
- * import { SetEnvironmentMaterial } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
260
+ * import { SetEnvironmentMaterial } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
306
261
  * window.env3DSource.apiReady = (api) => {
307
262
  * new SetEnvironmentMaterial(
308
263
  * 'ffea6b5c-3a8a-4f56-9417-e605acb5cca3',
@@ -332,11 +287,6 @@
332
287
  }
333
288
  }
334
289
 
335
- /*
336
- * Copyright (c) 2025.
337
- * 3DSource.com, Sergii Karanda steve@3dsource.com
338
- * All Rights Reserved
339
- */
340
290
  /**
341
291
  * {@inheritDoc ApiAction}
342
292
  *
@@ -347,7 +297,7 @@
347
297
  * **Important**: Invoking this action will buffer it until the viewport is ready. Only then will the request be processed.
348
298
  *
349
299
  * @example
350
- * import { GetFastRender,saveImage } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
300
+ * import { GetFastRender,saveImage } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
351
301
  * window.env3DSource.apiReady = (api) => {
352
302
  * // Listen for events from the MetaBox API
353
303
  * api.addEventListener('metaboxData', (data) => {
@@ -377,11 +327,6 @@
377
327
  }
378
328
  }
379
329
 
380
- /*
381
- * Copyright (c) 2025.
382
- * 3DSource.com, Sergii Karanda steve@3dsource.com
383
- * All Rights Reserved
384
- */
385
330
  /**
386
331
  * {@inheritDoc ApiAction}
387
332
  * @internal
@@ -398,11 +343,6 @@
398
343
  }
399
344
  }
400
345
 
401
- /*
402
- * Copyright (c) 2025.
403
- * 3DSource.com, Sergii Karanda steve@3dsource.com
404
- * All Rights Reserved
405
- */
406
346
  /**
407
347
  * @experimental
408
348
  * @internal
@@ -426,11 +366,6 @@
426
366
  }
427
367
  }
428
368
 
429
- /*
430
- * Copyright (c) 2025.
431
- * 3DSource.com, Sergii Karanda steve@3dsource.com
432
- * All Rights Reserved
433
- */
434
369
  /**
435
370
  * EventDispatcher is a class that manages event listeners and dispatches events to them.
436
371
  */
@@ -475,11 +410,6 @@
475
410
  }
476
411
  }
477
412
 
478
- /*
479
- * Copyright (c) 2025.
480
- * 3DSource.com, Sergii Karanda steve@3dsource.com
481
- * All Rights Reserved
482
- */
483
413
  const binderMessageType = 'metaboxData';
484
414
  /**
485
415
  * API class to handle communication with the embedded content.
@@ -574,11 +504,6 @@
574
504
  */
575
505
  Communicator.instance = null;
576
506
 
577
- /*
578
- * Copyright (c) 2025.
579
- * 3DSource.com, Sergii Karanda steve@3dsource.com
580
- * All Rights Reserved
581
- */
582
507
  /**
583
508
  * Integrates the MetaBox into the provided layout.
584
509
  *
@@ -601,7 +526,7 @@
601
526
  * @example
602
527
  * import {
603
528
  * integrateMetaBox,
604
- * } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
529
+ * } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
605
530
  *
606
531
  * integrateMetaBox(
607
532
  * 'https://metabox.3dsource.com/metabox-configurator/basic/12345678-1234-1234-1234-01234567890?introImage=https://example.com/intro.webp&sidebar=false',
@@ -635,11 +560,6 @@
635
560
  container.appendChild(iframe);
636
561
  }
637
562
 
638
- /*
639
- * Copyright (c) 2025.
640
- * 3DSource.com, Sergii Karanda steve@3dsource.com
641
- * All Rights Reserved
642
- */
643
563
  /**
644
564
  * Saves an image by triggering a download.
645
565
  *
@@ -659,11 +579,6 @@
659
579
  document.body.removeChild(a);
660
580
  }
661
581
 
662
- /*
663
- * Copyright (c) 2025.
664
- * 3DSource.com, Sergii Karanda steve@3dsource.com
665
- * All Rights Reserved
666
- */
667
582
  /**
668
583
  * Pauses execution for a specified duration.
669
584
  *
@@ -677,11 +592,6 @@
677
592
  return new Promise((resolve) => setTimeout(resolve, time));
678
593
  }
679
594
 
680
- /*
681
- * Copyright (c) 2025.
682
- * 3DSource.com, Sergii Karanda steve@3dsource.com
683
- * All Rights Reserved
684
- */
685
595
  /**
686
596
  * Sets the URL parameters based on the provided state.
687
597
  *
@@ -715,11 +625,6 @@
715
625
  return selections;
716
626
  }
717
627
 
718
- /*
719
- * Copyright (c) 2025.
720
- * 3DSource.com, Sergii Karanda steve@3dsource.com
721
- * All Rights Reserved
722
- */
723
628
  const FromMetaboxApiAction = {
724
629
  bridge: 'bridge',
725
630
  appLoaded: 'appLoaded',
@@ -776,11 +681,6 @@
776
681
  getFastRender: 'getFastRender',
777
682
  };
778
683
 
779
- /*
780
- * Copyright (c) 2025.
781
- * 3DSource.com, Sergii Karanda steve@3dsource.com
782
- * All Rights Reserved
783
- */
784
684
  const APPLICATION_DEVICE_TYPES = {
785
685
  deviceTypeAuto: 'deviceTypeAuto',
786
686
  deviceTypeMobile: 'deviceTypeMobile',
@@ -1 +1 @@
1
- {"version":3,"file":"index.umd.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.umd.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -20,7 +20,7 @@
20
20
  * @example
21
21
  * import {
22
22
  * integrateMetaBox,
23
- * } from 'https://unpkg.com/@3dsource/metabox-front-api@latest/dist/index.js';
23
+ * } from 'https://cdn.jsdelivr.net/npm/@3dsource/metabox-front-api@latest/dist/index.js';
24
24
  *
25
25
  * integrateMetaBox(
26
26
  * 'https://metabox.3dsource.com/metabox-configurator/basic/12345678-1234-1234-1234-01234567890?introImage=https://example.com/intro.webp&sidebar=false',
package/package.json CHANGED
@@ -1,12 +1,15 @@
1
1
  {
2
2
  "name": "@3dsource/metabox-front-api",
3
- "version": "0.0.16",
3
+ "version": "0.0.17",
4
4
  "description": "API for MetaBox BASIC configurator",
5
5
  "keywords": [
6
6
  "metabox",
7
7
  "api",
8
8
  "configurator"
9
9
  ],
10
+ "publishConfig": {
11
+ "access": "public"
12
+ },
10
13
  "repository": {
11
14
  "type": "git",
12
15
  "url": "git@bitbucket.org:dreamsoft/ams_vps-frontend.git"