@johnmorrisdotca/chikyu-earth 0.4.0 → 0.7.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.
Files changed (70) hide show
  1. package/CHANGELOG.md +78 -0
  2. package/NOTICE.md +39 -1
  3. package/README.md +199 -24
  4. package/dist/countries.d.ts +11 -0
  5. package/dist/countries.js +11 -0
  6. package/dist/element.d.ts +24 -1
  7. package/dist/element.js +70 -5
  8. package/dist/globe.d.ts +15 -1
  9. package/dist/globe.js +15 -1
  10. package/dist/index.d.ts +12 -1
  11. package/dist/index.js +12 -1
  12. package/dist/markers/cluster.d.ts +38 -0
  13. package/dist/markers/cluster.js +42 -0
  14. package/dist/markers/index.d.ts +5 -0
  15. package/dist/markers/index.js +6 -0
  16. package/dist/markers/labels.d.ts +64 -0
  17. package/dist/markers/labels.js +70 -0
  18. package/dist/markers/layer.d.ts +129 -0
  19. package/dist/markers/layer.js +455 -0
  20. package/dist/markers/project.d.ts +82 -0
  21. package/dist/markers/project.js +93 -0
  22. package/dist/markers/types.d.ts +83 -0
  23. package/dist/markers/types.js +1 -0
  24. package/dist/realistic/earth.d.ts +81 -0
  25. package/dist/realistic/earth.js +163 -0
  26. package/dist/realistic/element.d.ts +93 -0
  27. package/dist/realistic/element.js +284 -0
  28. package/dist/realistic/gate.d.ts +64 -0
  29. package/dist/realistic/gate.js +72 -0
  30. package/dist/realistic/index.d.ts +5 -0
  31. package/dist/realistic/index.js +6 -0
  32. package/dist/realistic/shaders.d.ts +10 -0
  33. package/dist/realistic/shaders.js +124 -0
  34. package/dist/realistic/shared.d.ts +23 -0
  35. package/dist/realistic/shared.js +51 -0
  36. package/dist/realistic/sun.d.ts +44 -0
  37. package/dist/realistic/sun.js +65 -0
  38. package/dist/realistic/textures.d.ts +40 -0
  39. package/dist/realistic/textures.js +141 -0
  40. package/dist/realistic/tiers.d.ts +94 -0
  41. package/dist/realistic/tiers.js +94 -0
  42. package/dist/rotate.d.ts +59 -4
  43. package/dist/rotate.js +59 -4
  44. package/dist/space/element.d.ts +134 -0
  45. package/dist/space/element.js +394 -0
  46. package/dist/space/ephemeris.d.ts +151 -0
  47. package/dist/space/ephemeris.js +162 -0
  48. package/dist/space/index.d.ts +3 -0
  49. package/dist/space/index.js +5 -0
  50. package/dist/space/scale.d.ts +124 -0
  51. package/dist/space/scale.js +141 -0
  52. package/dist/space/scene.d.ts +131 -0
  53. package/dist/space/scene.js +295 -0
  54. package/dist/styles.d.ts +65 -2
  55. package/dist/styles.js +43 -2
  56. package/dist/textures/clouds-1024.webp +0 -0
  57. package/dist/textures/clouds-2048.webp +0 -0
  58. package/dist/textures/day-1024.webp +0 -0
  59. package/dist/textures/day-2048.webp +0 -0
  60. package/dist/textures/day-4096.webp +0 -0
  61. package/dist/textures/moon-1024.webp +0 -0
  62. package/dist/textures/moon-2048.webp +0 -0
  63. package/dist/textures/night-1024.webp +0 -0
  64. package/dist/textures/night-2048.webp +0 -0
  65. package/dist/textures/water-1024.webp +0 -0
  66. package/dist/textures/water-2048.webp +0 -0
  67. package/dist/types.d.ts +55 -5
  68. package/dist/view.d.ts +64 -3
  69. package/dist/view.js +56 -3
  70. package/package.json +93 -8
package/dist/globe.js CHANGED
@@ -5,7 +5,21 @@ import { COUNTRIES } from "./countries.js";
5
5
  import { cleanStyle, STYLES } from "./styles.js";
6
6
  import { projectionView } from "./view.js";
7
7
  const SPHERE = { type: "Sphere" };
8
- /** The globe as an SVG string, turned to `rotation` and drawn in `style`, `size` pixels square. */
8
+ /**
9
+ * The globe as an SVG string, turned to `rotation` and drawn in `style`, `size` pixels square. It is pure: the same options always give the same markup, so it runs on a server, in a test or in a build step with no DOM.
10
+ *
11
+ * @param options - Size, turn, look and graticule; every one has a default, so `globe()` draws a 320-pixel globe facing the Greenwich meridian.
12
+ * @returns One `<svg>` element as text, with the country outlines as paths.
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * import { globe } from "@johnmorrisdotca/chikyu-earth";
17
+ *
18
+ * const svg = globe({ size: 240, rotation: [-139.7, -35.7], style: "line" });
19
+ * console.log(svg.slice(0, 60));
20
+ * console.log(svg.length > 10_000);
21
+ * ```
22
+ */
9
23
  export function globe(options = {}) {
10
24
  const size = options.size ?? 320;
11
25
  const style = STYLES[cleanStyle(options.style)];
package/dist/index.d.ts CHANGED
@@ -5,5 +5,16 @@ export { centreRotation, DEGREES_PER_MS, rotationAt, SIDEREAL_DAY_MS, spinAt } f
5
5
  export { globeBaseScale, HOME_VIEW, projectionView, type ProjectionView } from "./view.ts";
6
6
  export type { CountryProps, GeoPoint, GlobeOptions, GlobeView, Rotation } from "./types.ts";
7
7
  import type { CountryProps } from "./types.ts";
8
- /** Every country the globe draws, with its kuni name and code. */
8
+ /**
9
+ * Every country the globe draws, with its kuni name and code.
10
+ *
11
+ * @returns A list of English name, Japanese name (or `null`) and two-letter code (or `null` where a place has none).
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * import { countryList } from "@johnmorrisdotca/chikyu-earth";
16
+ *
17
+ * console.log(countryList().find((country) => country.alpha2 === "JP"));
18
+ * ```
19
+ */
9
20
  export declare const countryList: () => CountryProps[];
package/dist/index.js CHANGED
@@ -4,5 +4,16 @@ export { cleanStyle, DEFAULT_STYLE, STYLE_NAMES, STYLES } from "./styles.js";
4
4
  export { centreRotation, DEGREES_PER_MS, rotationAt, SIDEREAL_DAY_MS, spinAt } from "./rotate.js";
5
5
  export { globeBaseScale, HOME_VIEW, projectionView } from "./view.js";
6
6
  import { COUNTRIES } from "./countries.js";
7
- /** Every country the globe draws, with its kuni name and code. */
7
+ /**
8
+ * Every country the globe draws, with its kuni name and code.
9
+ *
10
+ * @returns A list of English name, Japanese name (or `null`) and two-letter code (or `null` where a place has none).
11
+ *
12
+ * @example
13
+ * ```ts
14
+ * import { countryList } from "@johnmorrisdotca/chikyu-earth";
15
+ *
16
+ * console.log(countryList().find((country) => country.alpha2 === "JP"));
17
+ * ```
18
+ */
8
19
  export const countryList = () => COUNTRIES.features.map((f) => f.properties);
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Several points gathered into one on the screen: where it is drawn and which points are in it.
3
+ *
4
+ * @example
5
+ * ```ts
6
+ * import { clusterPoints, type Cluster } from "@johnmorrisdotca/chikyu-earth/markers";
7
+ *
8
+ * const clusters: Cluster[] = clusterPoints([0, 1], 2, [10, 12], [10, 11], 28);
9
+ * console.log(clusters[0]?.members);
10
+ * ```
11
+ */
12
+ export interface Cluster {
13
+ x: number;
14
+ y: number;
15
+ /** Indices of the points in it. */
16
+ members: number[];
17
+ }
18
+ /**
19
+ * Group the points `indices` (into `xs` and `ys`) by the grid cell they fall in. A cell with one point is that point alone; with more it is one cluster at their
20
+ * average. Order is stable: clusters come in the order their first member was seen.
21
+ *
22
+ * @param indices - Which points to group: indices into `xs` and `ys`.
23
+ * @param count - How many of `indices` to read.
24
+ * @param xs - Every point's x on the screen, in pixels.
25
+ * @param ys - Every point's y on the screen, in pixels.
26
+ * @param cell - The side of a grid cell in pixels; points in one cell join.
27
+ * @returns The clusters, each with the indices of its members; a lone point is a cluster of one.
28
+ *
29
+ * @example
30
+ * ```ts
31
+ * import { clusterPoints } from "@johnmorrisdotca/chikyu-earth/markers";
32
+ *
33
+ * const xs = [10, 14, 200];
34
+ * const ys = [10, 12, 200];
35
+ * console.log(clusterPoints([0, 1, 2], 3, xs, ys, 28).map((cluster) => cluster.members));
36
+ * ```
37
+ */
38
+ export declare function clusterPoints(indices: ArrayLike<number>, count: number, xs: ArrayLike<number>, ys: ArrayLike<number>, cell: number): Cluster[];
@@ -0,0 +1,42 @@
1
+ // Crowded markers become one: points closer than a cell on the screen share a cluster. A grid, so thousands of points cost one pass. Pure.
2
+ /**
3
+ * Group the points `indices` (into `xs` and `ys`) by the grid cell they fall in. A cell with one point is that point alone; with more it is one cluster at their
4
+ * average. Order is stable: clusters come in the order their first member was seen.
5
+ *
6
+ * @param indices - Which points to group: indices into `xs` and `ys`.
7
+ * @param count - How many of `indices` to read.
8
+ * @param xs - Every point's x on the screen, in pixels.
9
+ * @param ys - Every point's y on the screen, in pixels.
10
+ * @param cell - The side of a grid cell in pixels; points in one cell join.
11
+ * @returns The clusters, each with the indices of its members; a lone point is a cluster of one.
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * import { clusterPoints } from "@johnmorrisdotca/chikyu-earth/markers";
16
+ *
17
+ * const xs = [10, 14, 200];
18
+ * const ys = [10, 12, 200];
19
+ * console.log(clusterPoints([0, 1, 2], 3, xs, ys, 28).map((cluster) => cluster.members));
20
+ * ```
21
+ */
22
+ export function clusterPoints(indices, count, xs, ys, cell) {
23
+ const cells = new Map();
24
+ const out = [];
25
+ for (let k = 0; k < count; k += 1) {
26
+ const i = indices[k];
27
+ const key = Math.floor(xs[i] / cell) * 100_003 + Math.floor(ys[i] / cell);
28
+ const found = cells.get(key);
29
+ if (found) {
30
+ const n = found.members.length;
31
+ found.x = (found.x * n + xs[i]) / (n + 1);
32
+ found.y = (found.y * n + ys[i]) / (n + 1);
33
+ found.members.push(i);
34
+ }
35
+ else {
36
+ const made = { x: xs[i], y: ys[i], members: [i] };
37
+ cells.set(key, made);
38
+ out.push(made);
39
+ }
40
+ }
41
+ return out;
42
+ }
@@ -0,0 +1,5 @@
1
+ export { attachMarkers, type Markers, type MarkerOptions, type OverlayElement, type OverlayHost, type OverlayPose } from "./layer.ts";
2
+ export { project, projectAll, canvasRatio, type Pose } from "./project.ts";
3
+ export { clusterPoints, type Cluster } from "./cluster.ts";
4
+ export { placeLabels, type LabelItem, type Placement } from "./labels.ts";
5
+ export type { GroupInfo, MarkerEventDetail, MarkerIcon, MarkerInput } from "./types.ts";
@@ -0,0 +1,6 @@
1
+ // Markers on the globe: `attachMarkers(element)` for `<chikyu-earth>` or `<chikyu-earth-realistic>`. The pure parts (projection, clusters, label placement)
2
+ // import on a server.
3
+ export { attachMarkers } from "./layer.js";
4
+ export { project, projectAll, canvasRatio } from "./project.js";
5
+ export { clusterPoints } from "./cluster.js";
6
+ export { placeLabels } from "./labels.js";
@@ -0,0 +1,64 @@
1
+ /**
2
+ * One label to place: its dot's centre and radius, its box's size and its priority.
3
+ *
4
+ * @example
5
+ * ```ts
6
+ * import type { LabelItem } from "@johnmorrisdotca/chikyu-earth/markers";
7
+ *
8
+ * const label: LabelItem = { x: 100, y: 100, r: 4, w: 60, h: 20, priority: 1 };
9
+ * console.log(label.w);
10
+ * ```
11
+ */
12
+ export interface LabelItem {
13
+ /** The dot's centre and radius. */
14
+ x: number;
15
+ y: number;
16
+ r: number;
17
+ /** The label's box size. */
18
+ w: number;
19
+ h: number;
20
+ /** Higher is placed first. */
21
+ priority: number;
22
+ }
23
+ /**
24
+ * Where one label goes: which item it is and its box's top-left corner.
25
+ *
26
+ * @example
27
+ * ```ts
28
+ * import { placeLabels, type Placement } from "@johnmorrisdotca/chikyu-earth/markers";
29
+ *
30
+ * const placed: Placement[] = placeLabels([{ x: 100, y: 100, r: 4, w: 60, h: 20, priority: 1 }], 300, 300, 10);
31
+ * console.log(placed[0]);
32
+ * ```
33
+ */
34
+ export interface Placement {
35
+ /** Index into the items given. */
36
+ item: number;
37
+ /** The label box's top-left corner. */
38
+ left: number;
39
+ top: number;
40
+ }
41
+ /**
42
+ * Place up to `max` labels inside `width` x `height`. Each label is tried to the right of its dot, then to the left, above and below; the first spot that is inside
43
+ * and free of the labels already placed wins. Items are taken highest priority first (a tie keeps the order given). The cost is the number of items times at most
44
+ * four tries against a grid of what is placed.
45
+ *
46
+ * @param items - The dots and the size of each one's label.
47
+ * @param width - The width of the area the labels must stay inside, in pixels.
48
+ * @param height - The height of that area, in pixels.
49
+ * @param max - The most labels to place.
50
+ * @param cell - The side of the grid cell used to find overlaps, in pixels.
51
+ * @returns A placement for each label that fits; the others are left out.
52
+ *
53
+ * @example
54
+ * ```ts
55
+ * import { placeLabels } from "@johnmorrisdotca/chikyu-earth/markers";
56
+ *
57
+ * const items = [
58
+ * { x: 100, y: 100, r: 4, w: 60, h: 20, priority: 1 },
59
+ * { x: 110, y: 104, r: 4, w: 60, h: 20, priority: 9 },
60
+ * ];
61
+ * console.log(placeLabels(items, 300, 300, 10).map((place) => place.item));
62
+ * ```
63
+ */
64
+ export declare function placeLabels(items: readonly LabelItem[], width: number, height: number, max: number, cell?: number): Placement[];
@@ -0,0 +1,70 @@
1
+ // Which labels to show: the most important first, each beside its dot, none over another label or a dot's label slot already taken. Pure.
2
+ const GAP = 3;
3
+ /**
4
+ * Place up to `max` labels inside `width` x `height`. Each label is tried to the right of its dot, then to the left, above and below; the first spot that is inside
5
+ * and free of the labels already placed wins. Items are taken highest priority first (a tie keeps the order given). The cost is the number of items times at most
6
+ * four tries against a grid of what is placed.
7
+ *
8
+ * @param items - The dots and the size of each one's label.
9
+ * @param width - The width of the area the labels must stay inside, in pixels.
10
+ * @param height - The height of that area, in pixels.
11
+ * @param max - The most labels to place.
12
+ * @param cell - The side of the grid cell used to find overlaps, in pixels.
13
+ * @returns A placement for each label that fits; the others are left out.
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * import { placeLabels } from "@johnmorrisdotca/chikyu-earth/markers";
18
+ *
19
+ * const items = [
20
+ * { x: 100, y: 100, r: 4, w: 60, h: 20, priority: 1 },
21
+ * { x: 110, y: 104, r: 4, w: 60, h: 20, priority: 9 },
22
+ * ];
23
+ * console.log(placeLabels(items, 300, 300, 10).map((place) => place.item));
24
+ * ```
25
+ */
26
+ export function placeLabels(items, width, height, max, cell = 64) {
27
+ const order = items.map((_, i) => i).sort((a, b) => items[b].priority - items[a].priority || a - b);
28
+ const grid = new Map();
29
+ const placed = [];
30
+ const keys = (box) => {
31
+ const out = [];
32
+ for (let gx = Math.floor(box.l / cell); gx <= Math.floor(box.r / cell); gx += 1)
33
+ for (let gy = Math.floor(box.t / cell); gy <= Math.floor(box.b / cell); gy += 1)
34
+ out.push(gx * 100_003 + gy);
35
+ return out;
36
+ };
37
+ const free = (box) => {
38
+ for (const key of keys(box))
39
+ for (const other of grid.get(key) ?? [])
40
+ if (box.l < other.r && box.r > other.l && box.t < other.b && box.b > other.t)
41
+ return false;
42
+ return true;
43
+ };
44
+ for (const index of order) {
45
+ if (placed.length >= max)
46
+ break;
47
+ const it = items[index];
48
+ const tries = [
49
+ [it.x + it.r + GAP, it.y - it.h / 2],
50
+ [it.x - it.r - GAP - it.w, it.y - it.h / 2],
51
+ [it.x - it.w / 2, it.y - it.r - GAP - it.h],
52
+ [it.x - it.w / 2, it.y + it.r + GAP],
53
+ ];
54
+ for (const [left, top] of tries) {
55
+ const box = { l: left, t: top, r: left + it.w, b: top + it.h };
56
+ if (box.l < 0 || box.t < 0 || box.r > width || box.b > height || !free(box))
57
+ continue;
58
+ for (const key of keys(box)) {
59
+ const list = grid.get(key);
60
+ if (list)
61
+ list.push(box);
62
+ else
63
+ grid.set(key, [box]);
64
+ }
65
+ placed.push({ item: index, left, top });
66
+ break;
67
+ }
68
+ }
69
+ return placed;
70
+ }
@@ -0,0 +1,129 @@
1
+ import { type Pose } from "./project.ts";
2
+ import type { GroupInfo, MarkerInput } from "./types.ts";
3
+ /** The view as an element tells it: the Pose, the size of the box it is drawn in, and the CSS transform its picture carries between redraws. */
4
+ /**
5
+ * The pose of an element's last drawing, with the size of its box and the CSS transform its picture carries between redraws.
6
+ *
7
+ * @example
8
+ * ```ts
9
+ * import type { OverlayPose } from "@johnmorrisdotca/chikyu-earth/markers";
10
+ *
11
+ * const where = (pose: OverlayPose): string => `${pose.lon}, ${pose.lat} at ${pose.width} x ${pose.height}`;
12
+ * console.log(typeof where);
13
+ * ```
14
+ */
15
+ export interface OverlayPose extends Pose {
16
+ width: number;
17
+ height: number;
18
+ transform: string;
19
+ }
20
+ /** What an element gives the markers: a box laid over its view, the pose of its last draw, and a way to hear the next ones. */
21
+ /**
22
+ * What an element gives the markers (`element.overlay`): a box laid over its view, the pose of its last draw, and a way to hear the next ones.
23
+ *
24
+ * @example
25
+ * ```ts
26
+ * import type { OverlayHost } from "@johnmorrisdotca/chikyu-earth/markers";
27
+ *
28
+ * const follow = (host: OverlayHost): (() => void) => host.subscribe((pose) => console.log(pose.radius));
29
+ * console.log(typeof follow);
30
+ * ```
31
+ */
32
+ export interface OverlayHost {
33
+ readonly overlayRoot: HTMLElement;
34
+ readonly pose: OverlayPose | null;
35
+ subscribe(listener: (pose: OverlayPose) => void): () => void;
36
+ }
37
+ /**
38
+ * What {@link attachMarkers} may be asked: the most labels, how close markers gather, and the default colour.
39
+ *
40
+ * @example
41
+ * ```ts
42
+ * import { attachMarkers, type MarkerOptions, type OverlayElement } from "@johnmorrisdotca/chikyu-earth/markers";
43
+ *
44
+ * const options: MarkerOptions = { maxLabels: 12, clusterRadius: 20, color: "#ffcc00" };
45
+ * const mark = (element: OverlayElement) => attachMarkers(element, options);
46
+ * console.log(typeof mark);
47
+ * ```
48
+ */
49
+ export interface MarkerOptions {
50
+ /** Most labels shown at once (24). */
51
+ maxLabels?: number;
52
+ /** Gather markers closer than this many pixels into a cluster (28); 0 turns clustering off. */
53
+ clusterRadius?: number;
54
+ /** The colour of a marker with none of its own. */
55
+ color?: string;
56
+ }
57
+ /**
58
+ * The markers on one globe: add, update, remove and find them, show or hide groups, and detach.
59
+ *
60
+ * @example
61
+ * ```ts no-run
62
+ * import { attachMarkers, type Markers, type OverlayElement } from "@johnmorrisdotca/chikyu-earth/markers";
63
+ *
64
+ * declare const earth: OverlayElement;
65
+ * const markers: Markers = attachMarkers(earth);
66
+ * markers.add({ id: "tokyo", lon: 139.69, lat: 35.69, label: "Tokyo", group: "Cities" });
67
+ * markers.toggleGroup("Cities");
68
+ * console.log(markers.size, markers.groups());
69
+ * ```
70
+ */
71
+ export interface Markers {
72
+ add(marker: MarkerInput): void;
73
+ addAll(markers: readonly MarkerInput[]): void;
74
+ update(id: string, patch: Partial<Omit<MarkerInput, "id">>): void;
75
+ remove(id: string): void;
76
+ clear(): void;
77
+ get(id: string): MarkerInput | undefined;
78
+ list(): MarkerInput[];
79
+ readonly size: number;
80
+ groups(): GroupInfo[];
81
+ showGroup(name: string): void;
82
+ hideGroup(name: string): void;
83
+ /** Show it if hidden and hide it if shown (or set it with `force`). Returns whether it is shown. */
84
+ toggleGroup(name: string, force?: boolean): boolean;
85
+ /** Markers and clusters drawn at the last render (for a page or a test). */
86
+ readonly stats: {
87
+ markers: number;
88
+ clusters: number;
89
+ labels: number;
90
+ renders: number;
91
+ };
92
+ detach(): void;
93
+ }
94
+ /**
95
+ * An element markers can be put on: any HTML element with an `overlay` (both `<chikyu-earth>` and `<chikyu-earth-realistic>` have one).
96
+ *
97
+ * @example
98
+ * ```ts
99
+ * import { attachMarkers, type OverlayElement } from "@johnmorrisdotca/chikyu-earth/markers";
100
+ *
101
+ * const mark = (element: OverlayElement) => attachMarkers(element);
102
+ * console.log(typeof mark);
103
+ * ```
104
+ */
105
+ export type OverlayElement = HTMLElement & {
106
+ overlay: OverlayHost;
107
+ };
108
+ /**
109
+ * Put markers on a globe, for either look: dots drawn in one pass on a canvas, a few labels as real buttons, crowded places gathered into clusters. It draws only when the view or the markers change, reads no layout to place a label, and shows no more labels than `maxLabels`. Hovering, clicking or focusing a marker fires `chikyu-marker-hover`, `chikyu-marker-click` and `chikyu-marker-focus` on the element, with your own `data` in the detail.
110
+ *
111
+ * @param element - `<chikyu-earth>` or `<chikyu-earth-realistic>`.
112
+ * @param options - The most labels, the cluster radius and the default colour; each has a default.
113
+ * @returns The markers: `add`, `addAll`, `update`, `remove`, `clear`, `groups`, `toggleGroup`, `stats` and `detach`.
114
+ *
115
+ * @example
116
+ * ```ts no-run
117
+ * import "@johnmorrisdotca/chikyu-earth/element";
118
+ * import { attachMarkers, type MarkerEventDetail } from "@johnmorrisdotca/chikyu-earth/markers";
119
+ *
120
+ * const earth = document.querySelector("chikyu-earth")!;
121
+ * const markers = attachMarkers(earth);
122
+ * markers.add({ id: "tokyo", lon: 139.69, lat: 35.69, label: "Tokyo", group: "Cities" });
123
+ * earth.addEventListener("chikyu-marker-click", (event) => {
124
+ * const { marker } = (event as CustomEvent<MarkerEventDetail>).detail;
125
+ * console.log("chose", marker?.label);
126
+ * });
127
+ * ```
128
+ */
129
+ export declare function attachMarkers(element: OverlayElement, options?: MarkerOptions): Markers;