@2112-lab/central-plant 0.3.15 → 0.3.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.
@@ -0,0 +1,679 @@
1
+ import { Loader, FileLoader, SRGBColorSpace, LinearSRGBColorSpace, BufferGeometry, BufferAttribute, Color, ColorManagement } from 'three';
2
+
3
+ const _taskCache = new WeakMap();
4
+
5
+ /**
6
+ * A loader for the Draco format.
7
+ *
8
+ * [Draco]{@link https://google.github.io/draco/} is an open source library for compressing
9
+ * and decompressing 3D meshes and point clouds. Compressed geometry can be significantly smaller,
10
+ * at the cost of additional decoding time on the client device.
11
+ *
12
+ * Standalone Draco files have a `.drc` extension, and contain vertex positions, normals, colors,
13
+ * and other attributes. Draco files do not contain materials, textures, animation, or node hierarchies –
14
+ * to use these features, embed Draco geometry inside of a glTF file. A normal glTF file can be converted
15
+ * to a Draco-compressed glTF file using [glTF-Pipeline]{@link https://github.com/CesiumGS/gltf-pipeline}.
16
+ * When using Draco with glTF, an instance of `DRACOLoader` will be used internally by {@link GLTFLoader}.
17
+ *
18
+ * It is recommended to create one DRACOLoader instance and reuse it to avoid loading and creating
19
+ * multiple decoder instances.
20
+ *
21
+ * `DRACOLoader` will automatically use either the JS or the WASM decoding library, based on
22
+ * browser capabilities.
23
+ *
24
+ * ```js
25
+ * const loader = new DRACOLoader();
26
+ * loader.setDecoderPath( '/examples/jsm/libs/draco/' );
27
+ *
28
+ * const geometry = await dracoLoader.loadAsync( 'models/draco/bunny.drc' );
29
+ * geometry.computeVertexNormals(); // optional
30
+ *
31
+ * dracoLoader.dispose();
32
+ * ```
33
+ *
34
+ * @augments Loader
35
+ * @three_import import { DRACOLoader } from 'three/addons/loaders/DRACOLoader.js';
36
+ */
37
+ class DRACOLoader extends Loader {
38
+
39
+ /**
40
+ * Constructs a new Draco loader.
41
+ *
42
+ * @param {LoadingManager} [manager] - The loading manager.
43
+ */
44
+ constructor( manager ) {
45
+
46
+ super( manager );
47
+
48
+ this.decoderPath = '';
49
+ this.decoderConfig = {};
50
+ this.decoderBinary = null;
51
+ this.decoderPending = null;
52
+
53
+ this.workerLimit = 4;
54
+ this.workerPool = [];
55
+ this.workerNextTaskID = 1;
56
+ this.workerSourceURL = '';
57
+
58
+ this.defaultAttributeIDs = {
59
+ position: 'POSITION',
60
+ normal: 'NORMAL',
61
+ color: 'COLOR',
62
+ uv: 'TEX_COORD'
63
+ };
64
+ this.defaultAttributeTypes = {
65
+ position: 'Float32Array',
66
+ normal: 'Float32Array',
67
+ color: 'Float32Array',
68
+ uv: 'Float32Array'
69
+ };
70
+
71
+ }
72
+
73
+ /**
74
+ * Provides configuration for the decoder libraries. Configuration cannot be changed after decoding begins.
75
+ *
76
+ * @param {string} path - The decoder path.
77
+ * @return {DRACOLoader} A reference to this loader.
78
+ */
79
+ setDecoderPath( path ) {
80
+
81
+ this.decoderPath = path;
82
+
83
+ return this;
84
+
85
+ }
86
+
87
+ /**
88
+ * Provides configuration for the decoder libraries. Configuration cannot be changed after decoding begins.
89
+ *
90
+ * @param {{type:('js'|'wasm')}} config - The decoder config.
91
+ * @return {DRACOLoader} A reference to this loader.
92
+ */
93
+ setDecoderConfig( config ) {
94
+
95
+ this.decoderConfig = config;
96
+
97
+ return this;
98
+
99
+ }
100
+
101
+ /**
102
+ * Sets the maximum number of Web Workers to be used during decoding.
103
+ * A lower limit may be preferable if workers are also for other tasks in the application.
104
+ *
105
+ * @param {number} workerLimit - The worker limit.
106
+ * @return {DRACOLoader} A reference to this loader.
107
+ */
108
+ setWorkerLimit( workerLimit ) {
109
+
110
+ this.workerLimit = workerLimit;
111
+
112
+ return this;
113
+
114
+ }
115
+
116
+ /**
117
+ * Starts loading from the given URL and passes the loaded Draco asset
118
+ * to the `onLoad()` callback.
119
+ *
120
+ * @param {string} url - The path/URL of the file to be loaded. This can also be a data URI.
121
+ * @param {function(BufferGeometry)} onLoad - Executed when the loading process has been finished.
122
+ * @param {onProgressCallback} onProgress - Executed while the loading is in progress.
123
+ * @param {onErrorCallback} onError - Executed when errors occur.
124
+ */
125
+ load( url, onLoad, onProgress, onError ) {
126
+
127
+ const loader = new FileLoader( this.manager );
128
+
129
+ loader.setPath( this.path );
130
+ loader.setResponseType( 'arraybuffer' );
131
+ loader.setRequestHeader( this.requestHeader );
132
+ loader.setWithCredentials( this.withCredentials );
133
+
134
+ loader.load( url, ( buffer ) => {
135
+
136
+ this.parse( buffer, onLoad, onError );
137
+
138
+ }, onProgress, onError );
139
+
140
+ }
141
+
142
+ /**
143
+ * Parses the given Draco data.
144
+ *
145
+ * @param {ArrayBuffer} buffer - The raw Draco data as an array buffer.
146
+ * @param {function(BufferGeometry)} onLoad - Executed when the loading/parsing process has been finished.
147
+ * @param {onErrorCallback} onError - Executed when errors occur.
148
+ */
149
+ parse( buffer, onLoad, onError = ()=>{} ) {
150
+
151
+ this.decodeDracoFile( buffer, onLoad, null, null, SRGBColorSpace, onError ).catch( onError );
152
+
153
+ }
154
+
155
+ //
156
+
157
+ decodeDracoFile( buffer, callback, attributeIDs, attributeTypes, vertexColorSpace = LinearSRGBColorSpace, onError = () => {} ) {
158
+
159
+ const taskConfig = {
160
+ attributeIDs: attributeIDs || this.defaultAttributeIDs,
161
+ attributeTypes: attributeTypes || this.defaultAttributeTypes,
162
+ useUniqueIDs: !! attributeIDs,
163
+ vertexColorSpace: vertexColorSpace,
164
+ };
165
+
166
+ return this.decodeGeometry( buffer, taskConfig ).then( callback ).catch( onError );
167
+
168
+ }
169
+
170
+ decodeGeometry( buffer, taskConfig ) {
171
+
172
+ const taskKey = JSON.stringify( taskConfig );
173
+
174
+ // Check for an existing task using this buffer. A transferred buffer cannot be transferred
175
+ // again from this thread.
176
+ if ( _taskCache.has( buffer ) ) {
177
+
178
+ const cachedTask = _taskCache.get( buffer );
179
+
180
+ if ( cachedTask.key === taskKey ) {
181
+
182
+ return cachedTask.promise;
183
+
184
+ } else if ( buffer.byteLength === 0 ) {
185
+
186
+ // Technically, it would be possible to wait for the previous task to complete,
187
+ // transfer the buffer back, and decode again with the second configuration. That
188
+ // is complex, and I don't know of any reason to decode a Draco buffer twice in
189
+ // different ways, so this is left unimplemented.
190
+ throw new Error(
191
+
192
+ 'THREE.DRACOLoader: Unable to re-decode a buffer with different ' +
193
+ 'settings. Buffer has already been transferred.'
194
+
195
+ );
196
+
197
+ }
198
+
199
+ }
200
+
201
+ //
202
+
203
+ let worker;
204
+ const taskID = this.workerNextTaskID ++;
205
+ const taskCost = buffer.byteLength;
206
+
207
+ // Obtain a worker and assign a task, and construct a geometry instance
208
+ // when the task completes.
209
+ const geometryPending = this._getWorker( taskID, taskCost )
210
+ .then( ( _worker ) => {
211
+
212
+ worker = _worker;
213
+
214
+ return new Promise( ( resolve, reject ) => {
215
+
216
+ worker._callbacks[ taskID ] = { resolve, reject };
217
+
218
+ worker.postMessage( { type: 'decode', id: taskID, taskConfig, buffer }, [ buffer ] );
219
+
220
+ // this.debug();
221
+
222
+ } );
223
+
224
+ } )
225
+ .then( ( message ) => this._createGeometry( message.geometry ) );
226
+
227
+ // Remove task from the task list.
228
+ // Note: replaced '.finally()' with '.catch().then()' block - iOS 11 support (#19416)
229
+ geometryPending
230
+ .catch( () => true )
231
+ .then( () => {
232
+
233
+ if ( worker && taskID ) {
234
+
235
+ this._releaseTask( worker, taskID );
236
+
237
+ // this.debug();
238
+
239
+ }
240
+
241
+ } );
242
+
243
+ // Cache the task result.
244
+ _taskCache.set( buffer, {
245
+
246
+ key: taskKey,
247
+ promise: geometryPending
248
+
249
+ } );
250
+
251
+ return geometryPending;
252
+
253
+ }
254
+
255
+ _createGeometry( geometryData ) {
256
+
257
+ const geometry = new BufferGeometry();
258
+
259
+ if ( geometryData.index ) {
260
+
261
+ geometry.setIndex( new BufferAttribute( geometryData.index.array, 1 ) );
262
+
263
+ }
264
+
265
+ for ( let i = 0; i < geometryData.attributes.length; i ++ ) {
266
+
267
+ const result = geometryData.attributes[ i ];
268
+ const name = result.name;
269
+ const array = result.array;
270
+ const itemSize = result.itemSize;
271
+
272
+ const attribute = new BufferAttribute( array, itemSize );
273
+
274
+ if ( name === 'color' ) {
275
+
276
+ this._assignVertexColorSpace( attribute, result.vertexColorSpace );
277
+
278
+ attribute.normalized = ( array instanceof Float32Array ) === false;
279
+
280
+ }
281
+
282
+ geometry.setAttribute( name, attribute );
283
+
284
+ }
285
+
286
+ return geometry;
287
+
288
+ }
289
+
290
+ _assignVertexColorSpace( attribute, inputColorSpace ) {
291
+
292
+ // While .drc files do not specify colorspace, the only 'official' tooling
293
+ // is PLY and OBJ converters, which use sRGB. We'll assume sRGB when a .drc
294
+ // file is passed into .load() or .parse(). GLTFLoader uses internal APIs
295
+ // to decode geometry, and vertex colors are already Linear-sRGB in there.
296
+
297
+ if ( inputColorSpace !== SRGBColorSpace ) return;
298
+
299
+ const _color = new Color();
300
+
301
+ for ( let i = 0, il = attribute.count; i < il; i ++ ) {
302
+
303
+ _color.fromBufferAttribute( attribute, i );
304
+ ColorManagement.colorSpaceToWorking( _color, SRGBColorSpace );
305
+ attribute.setXYZ( i, _color.r, _color.g, _color.b );
306
+
307
+ }
308
+
309
+ }
310
+
311
+ _loadLibrary( url, responseType ) {
312
+
313
+ const loader = new FileLoader( this.manager );
314
+ loader.setPath( this.decoderPath );
315
+ loader.setResponseType( responseType );
316
+ loader.setWithCredentials( this.withCredentials );
317
+
318
+ return new Promise( ( resolve, reject ) => {
319
+
320
+ loader.load( url, resolve, undefined, reject );
321
+
322
+ } );
323
+
324
+ }
325
+
326
+ preload() {
327
+
328
+ this._initDecoder();
329
+
330
+ return this;
331
+
332
+ }
333
+
334
+ _initDecoder() {
335
+
336
+ if ( this.decoderPending ) return this.decoderPending;
337
+
338
+ const useJS = typeof WebAssembly !== 'object' || this.decoderConfig.type === 'js';
339
+ const librariesPending = [];
340
+
341
+ if ( useJS ) {
342
+
343
+ librariesPending.push( this._loadLibrary( 'draco_decoder.js', 'text' ) );
344
+
345
+ } else {
346
+
347
+ librariesPending.push( this._loadLibrary( 'draco_wasm_wrapper.js', 'text' ) );
348
+ librariesPending.push( this._loadLibrary( 'draco_decoder.wasm', 'arraybuffer' ) );
349
+
350
+ }
351
+
352
+ this.decoderPending = Promise.all( librariesPending )
353
+ .then( ( libraries ) => {
354
+
355
+ const jsContent = libraries[ 0 ];
356
+
357
+ if ( ! useJS ) {
358
+
359
+ this.decoderConfig.wasmBinary = libraries[ 1 ];
360
+
361
+ }
362
+
363
+ const fn = DRACOWorker.toString();
364
+
365
+ const body = [
366
+ '/* draco decoder */',
367
+ jsContent,
368
+ '',
369
+ '/* worker */',
370
+ fn.substring( fn.indexOf( '{' ) + 1, fn.lastIndexOf( '}' ) )
371
+ ].join( '\n' );
372
+
373
+ this.workerSourceURL = URL.createObjectURL( new Blob( [ body ] ) );
374
+
375
+ } );
376
+
377
+ return this.decoderPending;
378
+
379
+ }
380
+
381
+ _getWorker( taskID, taskCost ) {
382
+
383
+ return this._initDecoder().then( () => {
384
+
385
+ if ( this.workerPool.length < this.workerLimit ) {
386
+
387
+ const worker = new Worker( this.workerSourceURL );
388
+
389
+ worker._callbacks = {};
390
+ worker._taskCosts = {};
391
+ worker._taskLoad = 0;
392
+
393
+ worker.postMessage( { type: 'init', decoderConfig: this.decoderConfig } );
394
+
395
+ worker.onmessage = function ( e ) {
396
+
397
+ const message = e.data;
398
+
399
+ switch ( message.type ) {
400
+
401
+ case 'decode':
402
+ worker._callbacks[ message.id ].resolve( message );
403
+ break;
404
+
405
+ case 'error':
406
+ worker._callbacks[ message.id ].reject( message );
407
+ break;
408
+
409
+ default:
410
+ console.error( 'THREE.DRACOLoader: Unexpected message, "' + message.type + '"' );
411
+
412
+ }
413
+
414
+ };
415
+
416
+ this.workerPool.push( worker );
417
+
418
+ } else {
419
+
420
+ this.workerPool.sort( function ( a, b ) {
421
+
422
+ return a._taskLoad > b._taskLoad ? - 1 : 1;
423
+
424
+ } );
425
+
426
+ }
427
+
428
+ const worker = this.workerPool[ this.workerPool.length - 1 ];
429
+ worker._taskCosts[ taskID ] = taskCost;
430
+ worker._taskLoad += taskCost;
431
+ return worker;
432
+
433
+ } );
434
+
435
+ }
436
+
437
+ _releaseTask( worker, taskID ) {
438
+
439
+ worker._taskLoad -= worker._taskCosts[ taskID ];
440
+ delete worker._callbacks[ taskID ];
441
+ delete worker._taskCosts[ taskID ];
442
+
443
+ }
444
+
445
+ debug() {
446
+
447
+ console.log( 'Task load: ', this.workerPool.map( ( worker ) => worker._taskLoad ) );
448
+
449
+ }
450
+
451
+ dispose() {
452
+
453
+ for ( let i = 0; i < this.workerPool.length; ++ i ) {
454
+
455
+ this.workerPool[ i ].terminate();
456
+
457
+ }
458
+
459
+ this.workerPool.length = 0;
460
+
461
+ if ( this.workerSourceURL !== '' ) {
462
+
463
+ URL.revokeObjectURL( this.workerSourceURL );
464
+
465
+ }
466
+
467
+ return this;
468
+
469
+ }
470
+
471
+ }
472
+
473
+ /* WEB WORKER */
474
+
475
+ function DRACOWorker() {
476
+
477
+ let decoderConfig;
478
+ let decoderPending;
479
+
480
+ onmessage = function ( e ) {
481
+
482
+ const message = e.data;
483
+
484
+ switch ( message.type ) {
485
+
486
+ case 'init':
487
+ decoderConfig = message.decoderConfig;
488
+ decoderPending = new Promise( function ( resolve/*, reject*/ ) {
489
+
490
+ decoderConfig.onModuleLoaded = function ( draco ) {
491
+
492
+ // Module is Promise-like. Wrap before resolving to avoid loop.
493
+ resolve( { draco: draco } );
494
+
495
+ };
496
+
497
+ DracoDecoderModule( decoderConfig ); // eslint-disable-line no-undef
498
+
499
+ } );
500
+ break;
501
+
502
+ case 'decode':
503
+ const buffer = message.buffer;
504
+ const taskConfig = message.taskConfig;
505
+ decoderPending.then( ( module ) => {
506
+
507
+ const draco = module.draco;
508
+ const decoder = new draco.Decoder();
509
+
510
+ try {
511
+
512
+ const geometry = decodeGeometry( draco, decoder, new Int8Array( buffer ), taskConfig );
513
+
514
+ const buffers = geometry.attributes.map( ( attr ) => attr.array.buffer );
515
+
516
+ if ( geometry.index ) buffers.push( geometry.index.array.buffer );
517
+
518
+ self.postMessage( { type: 'decode', id: message.id, geometry }, buffers );
519
+
520
+ } catch ( error ) {
521
+
522
+ console.error( error );
523
+
524
+ self.postMessage( { type: 'error', id: message.id, error: error.message } );
525
+
526
+ } finally {
527
+
528
+ draco.destroy( decoder );
529
+
530
+ }
531
+
532
+ } );
533
+ break;
534
+
535
+ }
536
+
537
+ };
538
+
539
+ function decodeGeometry( draco, decoder, array, taskConfig ) {
540
+
541
+ const attributeIDs = taskConfig.attributeIDs;
542
+ const attributeTypes = taskConfig.attributeTypes;
543
+
544
+ let dracoGeometry;
545
+ let decodingStatus;
546
+
547
+ const geometryType = decoder.GetEncodedGeometryType( array );
548
+
549
+ if ( geometryType === draco.TRIANGULAR_MESH ) {
550
+
551
+ dracoGeometry = new draco.Mesh();
552
+ decodingStatus = decoder.DecodeArrayToMesh( array, array.byteLength, dracoGeometry );
553
+
554
+ } else if ( geometryType === draco.POINT_CLOUD ) {
555
+
556
+ dracoGeometry = new draco.PointCloud();
557
+ decodingStatus = decoder.DecodeArrayToPointCloud( array, array.byteLength, dracoGeometry );
558
+
559
+ } else {
560
+
561
+ throw new Error( 'THREE.DRACOLoader: Unexpected geometry type.' );
562
+
563
+ }
564
+
565
+ if ( ! decodingStatus.ok() || dracoGeometry.ptr === 0 ) {
566
+
567
+ throw new Error( 'THREE.DRACOLoader: Decoding failed: ' + decodingStatus.error_msg() );
568
+
569
+ }
570
+
571
+ const geometry = { index: null, attributes: [] };
572
+
573
+ // Gather all vertex attributes.
574
+ for ( const attributeName in attributeIDs ) {
575
+
576
+ const attributeType = self[ attributeTypes[ attributeName ] ];
577
+
578
+ let attribute;
579
+ let attributeID;
580
+
581
+ // A Draco file may be created with default vertex attributes, whose attribute IDs
582
+ // are mapped 1:1 from their semantic name (POSITION, NORMAL, ...). Alternatively,
583
+ // a Draco file may contain a custom set of attributes, identified by known unique
584
+ // IDs. glTF files always do the latter, and `.drc` files typically do the former.
585
+ if ( taskConfig.useUniqueIDs ) {
586
+
587
+ attributeID = attributeIDs[ attributeName ];
588
+ attribute = decoder.GetAttributeByUniqueId( dracoGeometry, attributeID );
589
+
590
+ } else {
591
+
592
+ attributeID = decoder.GetAttributeId( dracoGeometry, draco[ attributeIDs[ attributeName ] ] );
593
+
594
+ if ( attributeID === - 1 ) continue;
595
+
596
+ attribute = decoder.GetAttribute( dracoGeometry, attributeID );
597
+
598
+ }
599
+
600
+ const attributeResult = decodeAttribute( draco, decoder, dracoGeometry, attributeName, attributeType, attribute );
601
+
602
+ if ( attributeName === 'color' ) {
603
+
604
+ attributeResult.vertexColorSpace = taskConfig.vertexColorSpace;
605
+
606
+ }
607
+
608
+ geometry.attributes.push( attributeResult );
609
+
610
+ }
611
+
612
+ // Add index.
613
+ if ( geometryType === draco.TRIANGULAR_MESH ) {
614
+
615
+ geometry.index = decodeIndex( draco, decoder, dracoGeometry );
616
+
617
+ }
618
+
619
+ draco.destroy( dracoGeometry );
620
+
621
+ return geometry;
622
+
623
+ }
624
+
625
+ function decodeIndex( draco, decoder, dracoGeometry ) {
626
+
627
+ const numFaces = dracoGeometry.num_faces();
628
+ const numIndices = numFaces * 3;
629
+ const byteLength = numIndices * 4;
630
+
631
+ const ptr = draco._malloc( byteLength );
632
+ decoder.GetTrianglesUInt32Array( dracoGeometry, byteLength, ptr );
633
+ const index = new Uint32Array( draco.HEAPF32.buffer, ptr, numIndices ).slice();
634
+ draco._free( ptr );
635
+
636
+ return { array: index, itemSize: 1 };
637
+
638
+ }
639
+
640
+ function decodeAttribute( draco, decoder, dracoGeometry, attributeName, attributeType, attribute ) {
641
+
642
+ const numComponents = attribute.num_components();
643
+ const numPoints = dracoGeometry.num_points();
644
+ const numValues = numPoints * numComponents;
645
+ const byteLength = numValues * attributeType.BYTES_PER_ELEMENT;
646
+ const dataType = getDracoDataType( draco, attributeType );
647
+
648
+ const ptr = draco._malloc( byteLength );
649
+ decoder.GetAttributeDataArrayForAllPoints( dracoGeometry, attribute, dataType, byteLength, ptr );
650
+ const array = new attributeType( draco.HEAPF32.buffer, ptr, numValues ).slice();
651
+ draco._free( ptr );
652
+
653
+ return {
654
+ name: attributeName,
655
+ array: array,
656
+ itemSize: numComponents
657
+ };
658
+
659
+ }
660
+
661
+ function getDracoDataType( draco, attributeType ) {
662
+
663
+ switch ( attributeType ) {
664
+
665
+ case Float32Array: return draco.DT_FLOAT32;
666
+ case Int8Array: return draco.DT_INT8;
667
+ case Int16Array: return draco.DT_INT16;
668
+ case Int32Array: return draco.DT_INT32;
669
+ case Uint8Array: return draco.DT_UINT8;
670
+ case Uint16Array: return draco.DT_UINT16;
671
+ case Uint32Array: return draco.DT_UINT32;
672
+
673
+ }
674
+
675
+ }
676
+
677
+ }
678
+
679
+ export { DRACOLoader };
@@ -31,7 +31,7 @@ var CentralPlant = /*#__PURE__*/function (_BaseDisposable) {
31
31
  * Initialize the CentralPlant manager
32
32
  *
33
33
  * @constructor
34
- * @version 0.3.15
34
+ * @version 0.3.17
35
35
  * @updated 2025-10-22
36
36
  *
37
37
  * @description Creates a new CentralPlant instance and initializes internal managers and utilities.
@@ -1065,7 +1065,7 @@ var CentralPlantInternals = /*#__PURE__*/function () {
1065
1065
  }));
1066
1066
  componentData.children.forEach(function (childData, index) {
1067
1067
  try {
1068
- var _childData$userData, _childData$userData2;
1068
+ var _childData$userData, _childData$userData2, _childData$userData3;
1069
1069
  // Create connector geometry (simple sphere for now)
1070
1070
  var connectorGeometry = new THREE.SphereGeometry(0.1, 8, 6);
1071
1071
  var connectorMaterial = new THREE.MeshPhysicalMaterial({
@@ -1101,7 +1101,8 @@ var CentralPlantInternals = /*#__PURE__*/function () {
1101
1101
  parentComponentId: componentId,
1102
1102
  connectorIndex: index,
1103
1103
  direction: ((_childData$userData = childData.userData) === null || _childData$userData === void 0 ? void 0 : _childData$userData.direction) || [0, 1, 0],
1104
- group: ((_childData$userData2 = childData.userData) === null || _childData$userData2 === void 0 ? void 0 : _childData$userData2.group) || null,
1104
+ flow: ((_childData$userData2 = childData.userData) === null || _childData$userData2 === void 0 ? void 0 : _childData$userData2.flow) || 'bi',
1105
+ group: ((_childData$userData3 = childData.userData) === null || _childData$userData3 === void 0 ? void 0 : _childData$userData3.group) || null,
1105
1106
  originalChildData: childData
1106
1107
  };
1107
1108