@yarrow-uz/yarrow-map-web-sdk 1.0.41 → 1.0.42
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 +11 -3
- package/dist/main.js +2 -2
- package/dist/maps/brandBadge.d.ts +1 -0
- package/dist/maps/yarrow.d.ts +5 -0
- package/dist/maps/yarrowControls.d.ts +9 -1
- package/dist/module.js +2 -2
- package/dist/react/index.js +1 -1
- package/dist/react/useYarrowMap.d.ts +1 -1
- package/package.json +1 -1
|
@@ -14,6 +14,7 @@ export declare class BrandBadgeController {
|
|
|
14
14
|
private state;
|
|
15
15
|
mount(container: HTMLElement, state: BrandBadgeState): void;
|
|
16
16
|
update(state: BrandBadgeState): void;
|
|
17
|
+
getHostElement(): HTMLDivElement | undefined;
|
|
17
18
|
teardown(removeHost?: boolean): void;
|
|
18
19
|
private getHostInlineStyle;
|
|
19
20
|
private applyHostStyles;
|
package/dist/maps/yarrow.d.ts
CHANGED
|
@@ -86,6 +86,7 @@ declare class YarrowMap {
|
|
|
86
86
|
layers: LayerDescriptor[];
|
|
87
87
|
private brandBadgeController;
|
|
88
88
|
private yarrowControlsController;
|
|
89
|
+
private badgeResizeObserver?;
|
|
89
90
|
constructor(config: YarrowMapConfig);
|
|
90
91
|
private ensureCacheProtocol;
|
|
91
92
|
private get cacheLifespanMs();
|
|
@@ -97,6 +98,10 @@ declare class YarrowMap {
|
|
|
97
98
|
private getIconsMap;
|
|
98
99
|
private addIconsToMap;
|
|
99
100
|
private patchMapRemoveForBadgeCleanup;
|
|
101
|
+
private getControlsInsetForCollision;
|
|
102
|
+
private syncOverlayCollisionInset;
|
|
103
|
+
private stopBadgeCollisionObserver;
|
|
104
|
+
private startBadgeCollisionObserver;
|
|
100
105
|
clearCache(): Promise<void>;
|
|
101
106
|
fixStyle(style: StyleSpecification | null | undefined): void;
|
|
102
107
|
init(): Promise<void>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Map as MaplibreMap } from 'maplibre-gl';
|
|
2
|
-
export type YarrowControlsPosition = 'left' | 'right';
|
|
2
|
+
export type YarrowControlsPosition = 'left' | 'left-top' | 'left-bottom' | 'right' | 'right-top' | 'right-bottom';
|
|
3
3
|
export type YarrowControlsConfig = {
|
|
4
4
|
enabled?: boolean;
|
|
5
5
|
position?: YarrowControlsPosition;
|
|
@@ -12,6 +12,12 @@ export type NormalizedYarrowControlsConfig = {
|
|
|
12
12
|
zoom: boolean;
|
|
13
13
|
compass: boolean;
|
|
14
14
|
};
|
|
15
|
+
type YarrowControlsInset = {
|
|
16
|
+
top: number;
|
|
17
|
+
right: number;
|
|
18
|
+
bottom: number;
|
|
19
|
+
left: number;
|
|
20
|
+
};
|
|
15
21
|
export declare const DEFAULT_YARROW_CONTROLS_CONFIG: NormalizedYarrowControlsConfig;
|
|
16
22
|
export declare const normalizeYarrowControlsConfig: (controls?: YarrowControlsConfig) => NormalizedYarrowControlsConfig;
|
|
17
23
|
type YarrowControlsState = {
|
|
@@ -30,9 +36,11 @@ export declare class YarrowControlsController {
|
|
|
30
36
|
private onZoomInClick?;
|
|
31
37
|
private onZoomOutClick?;
|
|
32
38
|
private onCompassClick?;
|
|
39
|
+
private inset;
|
|
33
40
|
private state;
|
|
34
41
|
mount(map: MaplibreMap, state: YarrowControlsState): void;
|
|
35
42
|
update(state: YarrowControlsState): void;
|
|
43
|
+
setInset(inset?: Partial<YarrowControlsInset>): void;
|
|
36
44
|
teardown(removeHost?: boolean): void;
|
|
37
45
|
private createDom;
|
|
38
46
|
private applyHostPosition;
|