@arenarium/maps 1.0.58 → 1.0.60
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/dist/index.d.ts +98 -17
- package/dist/index.js +33 -33
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -346,38 +346,64 @@ declare const mapEventMoveHandlerSchema: z.ZodFunction<z.ZodTuple<[
|
|
|
346
346
|
}>
|
|
347
347
|
], z.ZodUnknown>, z.ZodVoid>;
|
|
348
348
|
declare const mapEventClickHandlerSchema: z.ZodFunction<z.ZodTuple<[
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
349
|
+
z.ZodObject<{
|
|
350
|
+
lat: z.ZodNumber;
|
|
351
|
+
lng: z.ZodNumber;
|
|
352
|
+
}, "strip", z.ZodTypeAny, {
|
|
353
|
+
lat: number;
|
|
354
|
+
lng: number;
|
|
355
|
+
}, {
|
|
356
|
+
lat: number;
|
|
357
|
+
lng: number;
|
|
358
|
+
}>
|
|
356
359
|
], z.ZodUnknown>, z.ZodVoid>;
|
|
357
360
|
export interface EventPayloadMap {
|
|
358
361
|
idle: null;
|
|
359
362
|
move: MapPosition;
|
|
360
|
-
click:
|
|
361
|
-
popup_click: string;
|
|
362
|
-
loading_start: null;
|
|
363
|
-
loading_end: null;
|
|
363
|
+
click: MapCoordinate;
|
|
364
364
|
}
|
|
365
365
|
export interface EventHandlerMap {
|
|
366
366
|
idle: MapEventIdleHandler;
|
|
367
367
|
move: MapEventMoveHandler;
|
|
368
368
|
click: MapEventClickHandler;
|
|
369
|
-
popup_click: MapEventPopupClickHandler;
|
|
370
|
-
loading_start: MapEventLoadingStartHandler;
|
|
371
|
-
loading_end: MapEventLoadingEndHandler;
|
|
372
369
|
}
|
|
373
370
|
export type EventId = keyof EventHandlerMap;
|
|
374
371
|
export type EventHandler<E extends EventId> = (payload: EventPayloadMap[E]) => void;
|
|
375
372
|
export type MapEventIdleHandler = z.infer<typeof mapEventIdleHandlerSchema>;
|
|
376
373
|
export type MapEventMoveHandler = z.infer<typeof mapEventMoveHandlerSchema>;
|
|
377
374
|
export type MapEventClickHandler = z.infer<typeof mapEventClickHandlerSchema>;
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
375
|
+
declare const mapPopupDataSchema: z.ZodObject<{
|
|
376
|
+
id: z.ZodString;
|
|
377
|
+
rank: z.ZodNumber;
|
|
378
|
+
lat: z.ZodNumber;
|
|
379
|
+
lng: z.ZodNumber;
|
|
380
|
+
width: z.ZodNumber;
|
|
381
|
+
height: z.ZodNumber;
|
|
382
|
+
}, "strip", z.ZodTypeAny, {
|
|
383
|
+
lat: number;
|
|
384
|
+
lng: number;
|
|
385
|
+
id: string;
|
|
386
|
+
rank: number;
|
|
387
|
+
width: number;
|
|
388
|
+
height: number;
|
|
389
|
+
}, {
|
|
390
|
+
lat: number;
|
|
391
|
+
lng: number;
|
|
392
|
+
id: string;
|
|
393
|
+
rank: number;
|
|
394
|
+
width: number;
|
|
395
|
+
height: number;
|
|
396
|
+
}>;
|
|
397
|
+
declare const mapPopupStateSchema: z.ZodTuple<[
|
|
398
|
+
z.ZodNumber,
|
|
399
|
+
z.ZodArray<z.ZodTuple<[
|
|
400
|
+
z.ZodNumber,
|
|
401
|
+
z.ZodNumber
|
|
402
|
+
], null>, "many">
|
|
403
|
+
], null>;
|
|
404
|
+
declare const mapPopupContentCallbackSchema: z.ZodFunction<z.ZodTuple<[
|
|
405
|
+
z.ZodString
|
|
406
|
+
], z.ZodUnknown>, z.ZodPromise<z.ZodAny>>;
|
|
381
407
|
declare const mapPopupSchema: z.ZodObject<{
|
|
382
408
|
data: z.ZodObject<{
|
|
383
409
|
id: z.ZodString;
|
|
@@ -446,7 +472,62 @@ declare const mapPopupSchema: z.ZodObject<{
|
|
|
446
472
|
];
|
|
447
473
|
contentCallback: (args_0: string, ...args: unknown[]) => Promise<any>;
|
|
448
474
|
}>;
|
|
475
|
+
declare const mapPopupStatesRequestSchema: z.ZodObject<{
|
|
476
|
+
apiKey: z.ZodString;
|
|
477
|
+
data: z.ZodArray<z.ZodObject<{
|
|
478
|
+
id: z.ZodString;
|
|
479
|
+
rank: z.ZodNumber;
|
|
480
|
+
lat: z.ZodNumber;
|
|
481
|
+
lng: z.ZodNumber;
|
|
482
|
+
width: z.ZodNumber;
|
|
483
|
+
height: z.ZodNumber;
|
|
484
|
+
}, "strip", z.ZodTypeAny, {
|
|
485
|
+
lat: number;
|
|
486
|
+
lng: number;
|
|
487
|
+
id: string;
|
|
488
|
+
rank: number;
|
|
489
|
+
width: number;
|
|
490
|
+
height: number;
|
|
491
|
+
}, {
|
|
492
|
+
lat: number;
|
|
493
|
+
lng: number;
|
|
494
|
+
id: string;
|
|
495
|
+
rank: number;
|
|
496
|
+
width: number;
|
|
497
|
+
height: number;
|
|
498
|
+
}>, "many">;
|
|
499
|
+
minZoom: z.ZodNumber;
|
|
500
|
+
maxZoom: z.ZodNumber;
|
|
501
|
+
}, "strip", z.ZodTypeAny, {
|
|
502
|
+
minZoom: number;
|
|
503
|
+
maxZoom: number;
|
|
504
|
+
data: {
|
|
505
|
+
lat: number;
|
|
506
|
+
lng: number;
|
|
507
|
+
id: string;
|
|
508
|
+
rank: number;
|
|
509
|
+
width: number;
|
|
510
|
+
height: number;
|
|
511
|
+
}[];
|
|
512
|
+
apiKey: string;
|
|
513
|
+
}, {
|
|
514
|
+
minZoom: number;
|
|
515
|
+
maxZoom: number;
|
|
516
|
+
data: {
|
|
517
|
+
lat: number;
|
|
518
|
+
lng: number;
|
|
519
|
+
id: string;
|
|
520
|
+
rank: number;
|
|
521
|
+
width: number;
|
|
522
|
+
height: number;
|
|
523
|
+
}[];
|
|
524
|
+
apiKey: string;
|
|
525
|
+
}>;
|
|
526
|
+
export type MapPopupData = z.infer<typeof mapPopupDataSchema>;
|
|
527
|
+
export type MapPopupState = z.infer<typeof mapPopupStateSchema>;
|
|
528
|
+
export type MapPopupContentCallback = z.infer<typeof mapPopupContentCallbackSchema>;
|
|
449
529
|
export type MapPopup = z.infer<typeof mapPopupSchema>;
|
|
530
|
+
export type MapPopupStatesRequest = z.infer<typeof mapPopupStatesRequestSchema>;
|
|
450
531
|
export declare namespace MapComponent {
|
|
451
532
|
type MapPopupContentCallback = (id: string) => Promise<HTMLElement>;
|
|
452
533
|
}
|