@juun-roh/cesium-utils 0.1.3 → 0.2.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.
@@ -1,28 +1,4 @@
1
- import { Entity, Cesium3DTileFeature, GroundPrimitive, Primitive, Model, Cesium3DTileset, Color, Viewer } from 'cesium';
2
-
3
- interface IHighlight {
4
- show(object: any, options?: HighlightOptions): void;
5
- hide(): void;
6
- destroy(): void;
7
- color: Color;
8
- }
9
- interface HighlightOptions {
10
- /** Color of the highlight */
11
- color?: Color;
12
- /** To apply outline style for the highlight */
13
- outline?: boolean;
14
- /** Outline width */
15
- width?: number;
16
- }
17
- type PickedObject = {
18
- id?: Entity;
19
- primitive?: Primitive | GroundPrimitive | Model | Cesium3DTileset;
20
- tileset?: Cesium3DTileset;
21
- detail?: {
22
- model?: Model;
23
- };
24
- };
25
- type Picked = Entity | Cesium3DTileFeature | GroundPrimitive | PickedObject;
1
+ import { Viewer, Entity, Color, Primitive, GroundPrimitive, Model, Cesium3DTileset, Cesium3DTileFeature } from 'cesium';
26
2
 
27
3
  /**
28
4
  * @class
@@ -75,9 +51,9 @@ declare class Highlight {
75
51
  * Highlights a picked object or a direct instance.
76
52
  * @param picked The result of `Scene.pick()` or direct instance to be highlighted.
77
53
  * @param options Optional style for the highlight.
78
- * @see {@link HighlightOptions}
54
+ * @see {@link Highlight.Options}
79
55
  */
80
- show(picked: Picked, options?: HighlightOptions): void | Entity;
56
+ show(picked: Highlight.Picked, options?: Highlight.Options): void | Entity;
81
57
  private _getObject;
82
58
  /**
83
59
  * Clears the current highlight effects.
@@ -91,6 +67,32 @@ declare class Highlight {
91
67
  */
92
68
  set color(color: Color);
93
69
  }
70
+ declare namespace Highlight {
71
+ export interface Base {
72
+ show(object: any, options?: Highlight.Options): void;
73
+ hide(): void;
74
+ destroy(): void;
75
+ color: Color;
76
+ }
77
+ export interface Options {
78
+ /** Color of the highlight */
79
+ color?: Color;
80
+ /** To apply outline style for the highlight */
81
+ outline?: boolean;
82
+ /** Outline width */
83
+ width?: number;
84
+ }
85
+ type PickedObject = {
86
+ id?: Entity;
87
+ primitive?: Primitive | GroundPrimitive | Model | Cesium3DTileset;
88
+ tileset?: Cesium3DTileset;
89
+ detail?: {
90
+ model?: Model;
91
+ };
92
+ };
93
+ export type Picked = Entity | Cesium3DTileFeature | GroundPrimitive | PickedObject;
94
+ export { };
95
+ }
94
96
 
95
97
  /**
96
98
  * @class
@@ -114,7 +116,7 @@ declare class Highlight {
114
116
  * silhouetteHighlight.show(entity);
115
117
  * ```
116
118
  */
117
- declare class SilhouetteHighlight implements IHighlight {
119
+ declare class SilhouetteHighlight implements Highlight.Base {
118
120
  private _color;
119
121
  private _silhouette;
120
122
  private _composite;
@@ -132,15 +134,15 @@ declare class SilhouetteHighlight implements IHighlight {
132
134
  * @param object The object to be highlighted.
133
135
  * @param options Optional style for the highlight.
134
136
  */
135
- show(object: Cesium3DTileFeature, options?: HighlightOptions): void;
137
+ show(object: Cesium3DTileFeature, options?: Highlight.Options): void;
136
138
  /**
137
139
  * Highlights a picked `Entity` by updating the model properties.
138
140
  * @param object The object to be highlighted.
139
141
  * @param options Optional style for the highlight.
140
142
  */
141
- show(object: Entity, options?: HighlightOptions): void;
143
+ show(object: Entity, options?: Highlight.Options): void;
142
144
  /**
143
- * Compares two HighlightOptions objects for equality
145
+ * Compares two Highlight.Options objects for equality
144
146
  * @private
145
147
  */
146
148
  private _optionsEqual;
@@ -191,7 +193,7 @@ declare class SilhouetteHighlight implements IHighlight {
191
193
  * surfaceHighlight.show(entity);
192
194
  * ```
193
195
  */
194
- declare class SurfaceHighlight implements IHighlight {
196
+ declare class SurfaceHighlight implements Highlight.Base {
195
197
  private _color;
196
198
  private _entity;
197
199
  private _entities;
@@ -206,11 +208,11 @@ declare class SurfaceHighlight implements IHighlight {
206
208
  * Highlights a picked object by updating the reusable entity
207
209
  * @param object The object to be highlighted.
208
210
  * @param options Optional style for the highlight.
209
- * @see {@link HighlightOptions}
211
+ * @see {@link Highlight.Options}
210
212
  */
211
- show(object: Entity | GroundPrimitive, options?: HighlightOptions): Entity | undefined;
213
+ show(object: Entity | GroundPrimitive, options?: Highlight.Options): Entity | undefined;
212
214
  /**
213
- * Compares two HighlightOptions objects for equality
215
+ * Compares two Highlight.Options objects for equality
214
216
  * @private
215
217
  */
216
218
  private _optionsEqual;
@@ -240,4 +242,4 @@ declare class SurfaceHighlight implements IHighlight {
240
242
  get currentObject(): Entity | GroundPrimitive | undefined;
241
243
  }
242
244
 
243
- export { Highlight, type HighlightOptions, type IHighlight, type Picked, type PickedObject, SilhouetteHighlight, SurfaceHighlight };
245
+ export { Highlight, SilhouetteHighlight, SurfaceHighlight };
@@ -1 +1 @@
1
- import{a,b,c}from"../chunk-VMZ2PVXH.js";export{c as Highlight,a as SilhouetteHighlight,b as SurfaceHighlight};
1
+ import{a,b,c}from"../chunk-RZ3PTU3G.js";export{c as Highlight,a as SilhouetteHighlight,b as SurfaceHighlight};
@@ -0,0 +1,524 @@
1
+ import { DataSourceCollection, EntityCollection, ImageryLayerCollection, PrimitiveCollection, Billboard, Cesium3DTileset, GroundPrimitive, Label, PointPrimitive, Polyline, Primitive, DataSource, Entity, ImageryLayer } from 'cesium';
2
+
3
+ /**
4
+ * Examine the property descriptors at runtime
5
+ * to detect properties that only have getters.
6
+ * (read-only accessor properties)
7
+ * @param o The object to examine.
8
+ * @param k The key value of the property.
9
+ */
10
+ declare function isGetterOnly(o: object, k: string | number | symbol): boolean;
11
+ /**
12
+ * Runtime type validator to identify the non-function property.
13
+ */
14
+ type NonFunction<T> = {
15
+ [K in keyof T]: T[K] extends Function ? never : K;
16
+ }[keyof T];
17
+
18
+ /**
19
+ * @class
20
+ * A wrapper class that enhances Cesium collection objects with tagging functionality.
21
+ * This class provides a consistent API for working with different types of Cesium collections
22
+ * and allows grouping and manipulating collection items by custom tags.
23
+ *
24
+ * @template C - The type of Cesium collection (e.g., EntityCollection, PrimitiveCollection)
25
+ * @template I - The type of items in the collection (e.g., Entity, Primitive)
26
+ *
27
+ * @example
28
+ * // Example 1: Managing Complex Scene with Multiple Object Types
29
+ * class SceneOrganizer {
30
+ * private entities: Collection<EntityCollection, Entity>;
31
+ * private billboards: Collection<BillboardCollection, Billboard>;
32
+ * private primitives: Collection<PrimitiveCollection, Primitive>;
33
+ *
34
+ * constructor(viewer: Viewer) {
35
+ * this.entities = new Collection({ collection: viewer.entities });
36
+ * this.billboards = new Collection({
37
+ * collection: viewer.scene.primitives.add(new BillboardCollection())
38
+ * });
39
+ * this.primitives = new Collection({
40
+ * collection: viewer.scene.primitives
41
+ * });
42
+ * }
43
+ *
44
+ * // Unified API across different collection types!
45
+ * showLayer(layerName: string) {
46
+ * this.entities.show(layerName);
47
+ * this.billboards.show(layerName);
48
+ * this.primitives.show(layerName);
49
+ * }
50
+ *
51
+ * hideLayer(layerName: string) {
52
+ * this.entities.hide(layerName);
53
+ * this.billboards.hide(layerName);
54
+ * this.primitives.hide(layerName);
55
+ * }
56
+ *
57
+ * removeLayer(layerName: string) {
58
+ * this.entities.remove(layerName);
59
+ * this.billboards.remove(layerName);
60
+ * this.primitives.remove(layerName);
61
+ * }
62
+ * }
63
+ *
64
+ * // Example 2: Extend the class for Domain-Specific Needs
65
+ * class BuildingCollection extends Collection<EntityCollection, Entity> {
66
+ * constructor(viewer: Viewer) {
67
+ * super({ collection: viewer.entities, tag: 'buildings' });
68
+ * }
69
+ *
70
+ * addBuilding(options: {
71
+ * position: Cartesian3;
72
+ * height: number;
73
+ * floors: number;
74
+ * type: 'residential' | 'commercial' | 'industrial';
75
+ * }): Entity {
76
+ * const building = new Entity({
77
+ * position: options.position,
78
+ * box: {
79
+ * dimensions: new Cartesian3(50, 50, options.height),
80
+ * material: this.getMaterialForType(options.type)
81
+ * }
82
+ * });
83
+ *
84
+ * // Tag by type AND by floor count
85
+ * this.add(building, options.type);
86
+ * this.add(building, `floors-${options.floors}`);
87
+ *
88
+ * return building;
89
+ * }
90
+ *
91
+ * getByFloorRange(min: number, max: number): Entity[] {
92
+ * const results: Entity[] = [];
93
+ * for (let i = min; i <= max; i++) {
94
+ * results.push(...this.get(`floors-${i}`));
95
+ * }
96
+ * return results;
97
+ * }
98
+ *
99
+ * private getMaterialForType(type: string): Material {
100
+ * const colors = {
101
+ * residential: Color.GREEN,
102
+ * commercial: Color.BLUE,
103
+ * industrial: Color.YELLOW
104
+ * };
105
+ * return new ColorMaterialProperty(colors[type] || Color.WHITE);
106
+ * }
107
+ * }
108
+ */
109
+ declare class Collection<C extends Collection.Base, I extends Collection.Item> {
110
+ /**
111
+ * Symbol used as a property key to store tags on collection items.
112
+ * Using a Symbol ensures no property naming conflicts with the item's own properties.
113
+ * @readonly
114
+ */
115
+ static readonly symbol: unique symbol;
116
+ /**
117
+ * Default tag used when adding items without specifying a tag.
118
+ * @protected
119
+ */
120
+ protected tag: Collection.Tag;
121
+ /**
122
+ * The underlying Cesium collection being wrapped.
123
+ * @protected
124
+ */
125
+ protected collection: C;
126
+ /**
127
+ * Cache for values array to improve performance
128
+ * @private
129
+ */
130
+ private _valuesCache;
131
+ /**
132
+ * Tag to items map for faster lookups
133
+ * @private
134
+ */
135
+ private _tagMap;
136
+ /**
137
+ * Event listeners
138
+ * @private
139
+ */
140
+ private _eventListeners;
141
+ /**
142
+ * For cleaning up the instances
143
+ * @private
144
+ */
145
+ private _eventCleanupFunctions;
146
+ /**
147
+ * Creates a new Collection instance.
148
+ *
149
+ * @param options - Configuration options
150
+ * @param options.collection - The Cesium collection to wrap
151
+ * @param options.tag - The default tag to use for items (defaults to 'default')
152
+ */
153
+ constructor({ collection, tag }: {
154
+ collection: C;
155
+ tag?: Collection.Tag;
156
+ });
157
+ /**
158
+ * Makes the collection directly iterable, allowing it to be used in `for...of` loops
159
+ * and with spread operators.
160
+ *
161
+ * @returns An iterator for the items in the collection
162
+ *
163
+ * @example
164
+ * // Iterate through all items in the collection
165
+ * for (const entity of collection) {
166
+ * console.log(entity.id);
167
+ * }
168
+ *
169
+ * // Convert collection to array using spread syntax
170
+ * const entitiesArray = [...collection];
171
+ */
172
+ [Symbol.iterator](): Iterator<I>;
173
+ /**
174
+ * Emits an event to all registered listeners.
175
+ *
176
+ * @private
177
+ * @param type - The event type
178
+ * @param data - Additional event data
179
+ */
180
+ private _emit;
181
+ /**
182
+ * Adds an item to the internal tag map for quick lookups.
183
+ *
184
+ * @private
185
+ * @param item - The item to add
186
+ * @param tag - The tag to associate with the item
187
+ */
188
+ private _addToTagMap;
189
+ /**
190
+ * Removes an item from the internal tag map.
191
+ *
192
+ * @private
193
+ * @param item - The item to remove
194
+ */
195
+ private _removeFromTagMap;
196
+ /**
197
+ * Invalidates the values cache when collection changes.
198
+ *
199
+ * @private
200
+ */
201
+ private _invalidateCache;
202
+ /**
203
+ * Sets up automatic cache invalidation by registering event listeners on the underlying Cesium collection.
204
+ *
205
+ * @private
206
+ * @param collection - The Cesium collection to monitor for changes
207
+ *
208
+ * @see {@link destroy} For cleanup of event listeners
209
+ * @see {@link _invalidateCache} For the actual cache invalidation logic
210
+ */
211
+ private _setupCacheInvalidator;
212
+ /**
213
+ * Registers an event listener for collection events.
214
+ *
215
+ * @param type - The event type to listen for
216
+ * @param handler - The callback function
217
+ * @returns The collection instance for method chaining
218
+ */
219
+ addEventListener(type: Collection.Event, handler: Collection.EventHandler<I>): this;
220
+ /**
221
+ * Removes an event listener.
222
+ *
223
+ * @param type - The event type
224
+ * @param handler - The callback function to remove
225
+ * @returns The collection instance for method chaining
226
+ */
227
+ removeEventListener(type: Collection.Event, handler: Collection.EventHandler<I>): this;
228
+ /**
229
+ * Adds a single item with a tag to the collection.
230
+ *
231
+ * @param item - The item to add to the collection
232
+ * @param tag - Tag to associate with this item (defaults to the collection's default tag)
233
+ * @param index - The index to add the item at (if supported by the collection)
234
+ * @returns The collection instance for method chaining
235
+ *
236
+ * @example
237
+ * const entity = collection.add(new Entity({ ... }), 'landmarks');
238
+ */
239
+ add(item: I, tag?: Collection.Tag, index?: number): this;
240
+ /**
241
+ * Adds multiple items with the same tag to the collection.
242
+ *
243
+ * @param items - The array of items to add to the collection
244
+ * @param tag - Tag to associate with this item (defaults to the collection's default tag)
245
+ * @returns The collection instance for method chaining
246
+ *
247
+ * @example
248
+ * // Add multiple entities with the same tag
249
+ * const entities = [new Entity({ ... }), new Entity({ ... })];
250
+ * const addedEntities = collection.add(entities, 'buildings');
251
+ */
252
+ add(items: I[], tag?: Collection.Tag): this;
253
+ /**
254
+ * Returns true if the provided item is in this collection, false otherwise.
255
+ *
256
+ * @param item - The item instance to check for
257
+ * @returns True if the item is in the collection, false otherwise
258
+ */
259
+ contains(item: I): boolean;
260
+ /**
261
+ * Checks if the collection has any items with the specified tag.
262
+ *
263
+ * @param tag - The tag to check for
264
+ * @returns True if items with the tag exist, false otherwise
265
+ *
266
+ * @example
267
+ * if (collection.contains('temporary')) {
268
+ * console.log('Temporary items exist');
269
+ * }
270
+ */
271
+ contains(tag: Collection.Tag): boolean;
272
+ /**
273
+ * Removes an item from the collection.
274
+ *
275
+ * @param item - The item to remove
276
+ * @returns The collection instance for method chaining
277
+ */
278
+ remove(item: I): this;
279
+ /**
280
+ * Removes all items with the specified tag from the collection.
281
+ *
282
+ * @param by - The tag identifying which items to remove
283
+ * @returns The collection instance for method chaining
284
+ */
285
+ remove(by: Collection.Tag): this;
286
+ /**
287
+ * Removes all items with the array of tags from the collection.
288
+ *
289
+ * @param by - The tags identifying which items to remove
290
+ * @returns The collection instance for method chaining
291
+ */
292
+ remove(by: Collection.Tag[]): this;
293
+ /**
294
+ * Removes all items from the collection.
295
+ */
296
+ removeAll(): void;
297
+ /**
298
+ * Permanently destroys this Collection instance.
299
+ * Removes all event listeners and clears internal state.
300
+ * The Collection instance should not be used after calling this method.
301
+ */
302
+ destroy(): void;
303
+ /**
304
+ * Gets all item instances in the collection.
305
+ * This array should not be modified directly.
306
+ *
307
+ * @returns An array of all items in the collection
308
+ */
309
+ get values(): I[];
310
+ /**
311
+ * Gets the number of items in the collection.
312
+ *
313
+ * @returns The item count
314
+ */
315
+ get length(): number;
316
+ /**
317
+ * Gets all items with the specified tag from the collection.
318
+ * Uses an optimized internal map for faster lookups.
319
+ *
320
+ * @param by - The tag to filter by
321
+ * @returns An array of items with the specified tag, or an empty array if none found
322
+ *
323
+ * @example
324
+ * // Get all buildings
325
+ * const buildings = collection.get('buildings');
326
+ */
327
+ get(by: Collection.Tag): I[];
328
+ /**
329
+ * Gets the first item matching the tag. More efficient than `get` when
330
+ * you only need one item, especially for large collections.
331
+ *
332
+ * @param by - The tag to search for
333
+ * @returns The first matching item or undefined if none found
334
+ *
335
+ * @example
336
+ * // Get the first building
337
+ * const firstBuilding = collection.first('buildings');
338
+ */
339
+ first(by: Collection.Tag): I | undefined;
340
+ /**
341
+ * Gets all unique tags currently in use in the collection.
342
+ *
343
+ * @returns An array of all unique tags
344
+ *
345
+ * @example
346
+ * // Get all tags
347
+ * const tags = collection.tags;
348
+ * console.log(`Collection has these tags: ${tags.join(', ')}`);
349
+ */
350
+ get tags(): Collection.Tag[];
351
+ /**
352
+ * Updates the tag for all items with the specified tag.
353
+ *
354
+ * @param from - The tag to replace
355
+ * @param to - The new tag to assign
356
+ * @returns The number of items updated
357
+ *
358
+ * @example
359
+ * // Rename a tag
360
+ * const count = collection.update('temp', 'temporary');
361
+ * console.log(`Updated ${count} items`);
362
+ */
363
+ update(from: Collection.Tag, to: Collection.Tag): number;
364
+ /**
365
+ * Makes all items with the specified tag visible.
366
+ * Only affects items that have a 'show' property.
367
+ *
368
+ * @param by - The tag identifying which items to show
369
+ * @returns The collection itself.
370
+ *
371
+ * @example
372
+ * // Show all buildings
373
+ * collection.show('buildings');
374
+ */
375
+ show(by: Collection.Tag): this;
376
+ /**
377
+ * Hides all items with the specified tag.
378
+ * Only affects items that have a 'show' property.
379
+ *
380
+ * @param by - The tag identifying which items to hide
381
+ * @returns The collection itself.
382
+ *
383
+ * @example
384
+ * // Hide all buildings
385
+ * collection.hide('buildings');
386
+ */
387
+ hide(by: Collection.Tag): this;
388
+ /**
389
+ * Toggles visibility of all items with the specified tag.
390
+ * Only affects items that have a 'show' property.
391
+ *
392
+ * @param by - The tag identifying which items to toggle
393
+ * @returns The collection itself.
394
+ *
395
+ * @example
396
+ * // Toggle visibility of all buildings
397
+ * collection.toggle('buildings');
398
+ */
399
+ toggle(by: Collection.Tag): this;
400
+ /**
401
+ * Sets a property value on all items with the specified tag.
402
+ *
403
+ * @template K - A type
404
+ *
405
+ * @param by - The tag identifying which items to update
406
+ * @param property - The property name to set
407
+ * @param value - The value to set
408
+ * @returns The collection itself.
409
+ *
410
+ * @example
411
+ * // Change color of all buildings to red
412
+ * collection.setProperty('buildings', 'color', Color.RED);
413
+ */
414
+ setProperty<K extends NonFunction<I>>(property: K, value: I[K], by?: Collection.Tag): this;
415
+ /**
416
+ * Filters items in the collection based on a predicate function.
417
+ * Optionally only filters items with a specific tag.
418
+ *
419
+ * @param predicate - Function that tests each item
420
+ * @param by - Optional tag to filter by before applying the predicate
421
+ * @returns Array of items that pass the test
422
+ *
423
+ * @example
424
+ * // Get all buildings taller than 100 meters
425
+ * const tallBuildings = collection.filter(
426
+ * entity => entity.properties?.height?.getValue() > 100,
427
+ * 'buildings'
428
+ * );
429
+ */
430
+ filter(predicate: (item: I) => boolean, by?: Collection.Tag): I[];
431
+ /**
432
+ * Executes a callback function for each item in the collection.
433
+ * Optionally filters items by tag before execution.
434
+ *
435
+ * @param callback - Function to execute for each item
436
+ * @param by - Optional tag to filter items (if not provided, processes all items)
437
+ *
438
+ * @example
439
+ * // Highlight all buildings
440
+ * collection.forEach((entity) => {
441
+ * if (entity.polygon) {
442
+ * entity.polygon.material = new ColorMaterialProperty(Color.YELLOW);
443
+ * }
444
+ * }, 'buildings');
445
+ */
446
+ forEach(callback: (value: I, index: number) => void, by?: Collection.Tag): void;
447
+ /**
448
+ * Creates a new array with the results of calling a provided function on every element
449
+ * in the collection. Optionally filters by tag before mapping.
450
+ *
451
+ * @param callbackfn - Function that produces an element of the new array
452
+ * @param by - Optional tag to filter items by before mapping
453
+ * @returns A new array with each element being the result of the callback function
454
+ *
455
+ * @example
456
+ * // Get all entity IDs
457
+ * const entityIds = collection.map(entity => entity.id);
458
+ *
459
+ * // Get positions of all buildings
460
+ * const buildingPositions = collection.map(
461
+ * entity => entity.position.getValue(Cesium.JulianDate.now()),
462
+ * 'buildings'
463
+ * );
464
+ */
465
+ map<R>(callbackfn: (value: I, index: number) => R, by?: Collection.Tag): R[];
466
+ /**
467
+ * Returns the first element in the collection that satisfies the provided testing function.
468
+ * Optionally filters by tag before searching.
469
+ *
470
+ * @param predicate - Function to test each element
471
+ * @param by - Optional tag to filter items by before searching
472
+ * @returns The first element that passes the test, or undefined if no elements pass
473
+ *
474
+ * @example
475
+ * // Find the first entity with a specific name
476
+ * const namedEntity = collection.find(entity => entity.name === 'Target');
477
+ *
478
+ * // Find the first building taller than 100 meters
479
+ * const tallBuilding = collection.find(
480
+ * entity => entity.properties?.height?.getValue() > 100,
481
+ * 'buildings'
482
+ * );
483
+ */
484
+ find(predicate: (value: I) => boolean, by?: Collection.Tag): I | undefined;
485
+ }
486
+ /**
487
+ * @namespace
488
+ */
489
+ declare namespace Collection {
490
+ /**
491
+ * The underlying Cesium collection type being wrapped.
492
+ */
493
+ export type Base = DataSourceCollection | EntityCollection | ImageryLayerCollection | PrimitiveCollection;
494
+ /**
495
+ * The item types that can be added to the `PrimitiveCollection` instance.
496
+ */
497
+ type Primitives = Billboard | Cesium3DTileset | GroundPrimitive | Label | PointPrimitive | Polyline | Primitive;
498
+ /**
499
+ * Cesium item type that can be added to the {@link Collection.Base} instance.
500
+ */
501
+ export type Item = DataSource | Entity | ImageryLayer | Primitives;
502
+ /**
503
+ * Collection tag type.
504
+ */
505
+ export type Tag = string | number;
506
+ export interface WithTag {
507
+ [key: symbol]: Tag;
508
+ }
509
+ /**
510
+ * Collection event types
511
+ */
512
+ export type Event = "add" | "remove" | "update" | "clear";
513
+ /**
514
+ * Event handler function type
515
+ */
516
+ export type EventHandler<I> = (event: {
517
+ type: Event;
518
+ items?: I[];
519
+ tag?: Collection.Tag;
520
+ }) => void;
521
+ export { };
522
+ }
523
+
524
+ export { Collection as C, type NonFunction as N, isGetterOnly as i };