@antv/l7-map 2.25.5 → 2.25.7

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 (159) hide show
  1. package/package.json +2 -2
  2. package/es/index.d.ts +0 -5
  3. package/es/index.js +0 -4
  4. package/es/map/camera.d.ts +0 -690
  5. package/es/map/camera.js +0 -1138
  6. package/es/map/css/l7.css +0 -171
  7. package/es/map/events.d.ts +0 -384
  8. package/es/map/events.js +0 -231
  9. package/es/map/geo/edge_insets.d.ts +0 -97
  10. package/es/map/geo/edge_insets.js +0 -115
  11. package/es/map/geo/lng_lat.d.ts +0 -116
  12. package/es/map/geo/lng_lat.js +0 -159
  13. package/es/map/geo/lng_lat_bounds.d.ts +0 -217
  14. package/es/map/geo/lng_lat_bounds.js +0 -334
  15. package/es/map/geo/mercator_coordinate.d.ts +0 -113
  16. package/es/map/geo/mercator_coordinate.js +0 -142
  17. package/es/map/geo/transform.d.ts +0 -262
  18. package/es/map/geo/transform.js +0 -736
  19. package/es/map/handler/box_zoom.d.ts +0 -65
  20. package/es/map/handler/box_zoom.js +0 -145
  21. package/es/map/handler/click_zoom.d.ts +0 -24
  22. package/es/map/handler/click_zoom.js +0 -47
  23. package/es/map/handler/cooperative_gestures.d.ts +0 -40
  24. package/es/map/handler/cooperative_gestures.js +0 -94
  25. package/es/map/handler/drag_handler.d.ts +0 -88
  26. package/es/map/handler/drag_handler.js +0 -89
  27. package/es/map/handler/drag_move_state_manager.d.ts +0 -30
  28. package/es/map/handler/drag_move_state_manager.js +0 -94
  29. package/es/map/handler/handler_util.d.ts +0 -3
  30. package/es/map/handler/handler_util.js +0 -8
  31. package/es/map/handler/keyboard.d.ts +0 -88
  32. package/es/map/handler/keyboard.js +0 -197
  33. package/es/map/handler/map_event.d.ts +0 -46
  34. package/es/map/handler/map_event.js +0 -131
  35. package/es/map/handler/mouse.d.ts +0 -30
  36. package/es/map/handler/mouse.js +0 -85
  37. package/es/map/handler/one_finger_touch_drag.d.ts +0 -15
  38. package/es/map/handler/one_finger_touch_drag.js +0 -39
  39. package/es/map/handler/scroll_zoom.d.ts +0 -102
  40. package/es/map/handler/scroll_zoom.js +0 -312
  41. package/es/map/handler/shim/dblclick_zoom.d.ts +0 -44
  42. package/es/map/handler/shim/dblclick_zoom.js +0 -60
  43. package/es/map/handler/shim/drag_pan.d.ts +0 -79
  44. package/es/map/handler/shim/drag_pan.js +0 -77
  45. package/es/map/handler/shim/drag_rotate.d.ts +0 -54
  46. package/es/map/handler/shim/drag_rotate.js +0 -66
  47. package/es/map/handler/shim/two_fingers_touch.d.ts +0 -74
  48. package/es/map/handler/shim/two_fingers_touch.js +0 -106
  49. package/es/map/handler/tap_drag_zoom.d.ts +0 -28
  50. package/es/map/handler/tap_drag_zoom.js +0 -92
  51. package/es/map/handler/tap_recognizer.d.ts +0 -35
  52. package/es/map/handler/tap_recognizer.js +0 -107
  53. package/es/map/handler/tap_zoom.d.ts +0 -28
  54. package/es/map/handler/tap_zoom.js +0 -87
  55. package/es/map/handler/touch_pan.d.ts +0 -40
  56. package/es/map/handler/touch_pan.js +0 -85
  57. package/es/map/handler/transform-provider.d.ts +0 -23
  58. package/es/map/handler/transform-provider.js +0 -35
  59. package/es/map/handler/two_fingers_touch.d.ts +0 -107
  60. package/es/map/handler/two_fingers_touch.js +0 -289
  61. package/es/map/handler_inertia.d.ts +0 -20
  62. package/es/map/handler_inertia.js +0 -128
  63. package/es/map/handler_manager.d.ts +0 -154
  64. package/es/map/handler_manager.js +0 -466
  65. package/es/map/map.d.ts +0 -637
  66. package/es/map/map.js +0 -984
  67. package/es/map/util/abort_error.d.ts +0 -15
  68. package/es/map/util/abort_error.js +0 -21
  69. package/es/map/util/browser.d.ts +0 -10
  70. package/es/map/util/browser.js +0 -30
  71. package/es/map/util/dom.d.ts +0 -30
  72. package/es/map/util/dom.js +0 -105
  73. package/es/map/util/evented.d.ts +0 -75
  74. package/es/map/util/evented.js +0 -158
  75. package/es/map/util/simpleMapCoord.d.ts +0 -31
  76. package/es/map/util/simpleMapCoord.js +0 -54
  77. package/es/map/util/task_queue.d.ts +0 -18
  78. package/es/map/util/task_queue.js +0 -54
  79. package/es/map/util/util.d.ts +0 -104
  80. package/es/map/util/util.js +0 -155
  81. package/lib/index.d.ts +0 -5
  82. package/lib/index.js +0 -33
  83. package/lib/map/camera.d.ts +0 -690
  84. package/lib/map/camera.js +0 -1145
  85. package/lib/map/css/l7.css +0 -171
  86. package/lib/map/events.d.ts +0 -384
  87. package/lib/map/events.js +0 -240
  88. package/lib/map/geo/edge_insets.d.ts +0 -97
  89. package/lib/map/geo/edge_insets.js +0 -122
  90. package/lib/map/geo/lng_lat.d.ts +0 -116
  91. package/lib/map/geo/lng_lat.js +0 -166
  92. package/lib/map/geo/lng_lat_bounds.d.ts +0 -217
  93. package/lib/map/geo/lng_lat_bounds.js +0 -341
  94. package/lib/map/geo/mercator_coordinate.d.ts +0 -113
  95. package/lib/map/geo/mercator_coordinate.js +0 -157
  96. package/lib/map/geo/transform.d.ts +0 -262
  97. package/lib/map/geo/transform.js +0 -744
  98. package/lib/map/handler/box_zoom.d.ts +0 -65
  99. package/lib/map/handler/box_zoom.js +0 -153
  100. package/lib/map/handler/click_zoom.d.ts +0 -24
  101. package/lib/map/handler/click_zoom.js +0 -54
  102. package/lib/map/handler/cooperative_gestures.d.ts +0 -40
  103. package/lib/map/handler/cooperative_gestures.js +0 -101
  104. package/lib/map/handler/drag_handler.d.ts +0 -88
  105. package/lib/map/handler/drag_handler.js +0 -97
  106. package/lib/map/handler/drag_move_state_manager.d.ts +0 -30
  107. package/lib/map/handler/drag_move_state_manager.js +0 -103
  108. package/lib/map/handler/handler_util.d.ts +0 -3
  109. package/lib/map/handler/handler_util.js +0 -14
  110. package/lib/map/handler/keyboard.d.ts +0 -88
  111. package/lib/map/handler/keyboard.js +0 -205
  112. package/lib/map/handler/map_event.d.ts +0 -46
  113. package/lib/map/handler/map_event.js +0 -140
  114. package/lib/map/handler/mouse.d.ts +0 -30
  115. package/lib/map/handler/mouse.js +0 -93
  116. package/lib/map/handler/one_finger_touch_drag.d.ts +0 -15
  117. package/lib/map/handler/one_finger_touch_drag.js +0 -47
  118. package/lib/map/handler/scroll_zoom.d.ts +0 -102
  119. package/lib/map/handler/scroll_zoom.js +0 -320
  120. package/lib/map/handler/shim/dblclick_zoom.d.ts +0 -44
  121. package/lib/map/handler/shim/dblclick_zoom.js +0 -68
  122. package/lib/map/handler/shim/drag_pan.d.ts +0 -79
  123. package/lib/map/handler/shim/drag_pan.js +0 -85
  124. package/lib/map/handler/shim/drag_rotate.d.ts +0 -54
  125. package/lib/map/handler/shim/drag_rotate.js +0 -74
  126. package/lib/map/handler/shim/two_fingers_touch.d.ts +0 -74
  127. package/lib/map/handler/shim/two_fingers_touch.js +0 -114
  128. package/lib/map/handler/tap_drag_zoom.d.ts +0 -28
  129. package/lib/map/handler/tap_drag_zoom.js +0 -99
  130. package/lib/map/handler/tap_recognizer.d.ts +0 -35
  131. package/lib/map/handler/tap_recognizer.js +0 -116
  132. package/lib/map/handler/tap_zoom.d.ts +0 -28
  133. package/lib/map/handler/tap_zoom.js +0 -94
  134. package/lib/map/handler/touch_pan.d.ts +0 -40
  135. package/lib/map/handler/touch_pan.js +0 -92
  136. package/lib/map/handler/transform-provider.d.ts +0 -23
  137. package/lib/map/handler/transform-provider.js +0 -43
  138. package/lib/map/handler/two_fingers_touch.d.ts +0 -107
  139. package/lib/map/handler/two_fingers_touch.js +0 -296
  140. package/lib/map/handler_inertia.d.ts +0 -20
  141. package/lib/map/handler_inertia.js +0 -136
  142. package/lib/map/handler_manager.d.ts +0 -154
  143. package/lib/map/handler_manager.js +0 -474
  144. package/lib/map/map.d.ts +0 -637
  145. package/lib/map/map.js +0 -991
  146. package/lib/map/util/abort_error.d.ts +0 -15
  147. package/lib/map/util/abort_error.js +0 -29
  148. package/lib/map/util/browser.d.ts +0 -10
  149. package/lib/map/util/browser.js +0 -36
  150. package/lib/map/util/dom.d.ts +0 -30
  151. package/lib/map/util/dom.js +0 -113
  152. package/lib/map/util/evented.d.ts +0 -75
  153. package/lib/map/util/evented.js +0 -167
  154. package/lib/map/util/simpleMapCoord.d.ts +0 -31
  155. package/lib/map/util/simpleMapCoord.js +0 -62
  156. package/lib/map/util/task_queue.d.ts +0 -18
  157. package/lib/map/util/task_queue.js +0 -62
  158. package/lib/map/util/util.d.ts +0 -104
  159. package/lib/map/util/util.js +0 -171
@@ -1,104 +0,0 @@
1
- export declare const interpolates: {
2
- number: (from: number, to: number, t: number) => number;
3
- };
4
- /**
5
- * constrain n to the given range via min + max
6
- *
7
- * @param n - value
8
- * @param min - the minimum value to be returned
9
- * @param max - the maximum value to be returned
10
- * @returns the clamped value
11
- */
12
- export declare function clamp(n: number, min: number, max: number): number;
13
- /**
14
- * constrain n to the given range, excluding the minimum, via modular arithmetic
15
- *
16
- * @param n - value
17
- * @param min - the minimum value to be returned, exclusive
18
- * @param max - the maximum value to be returned, inclusive
19
- * @returns constrained number
20
- */
21
- export declare function wrap(n: number, min: number, max: number): number;
22
- /**
23
- * Return a unique numeric id, starting at 1 and incrementing with
24
- * each call.
25
- *
26
- * @returns unique numeric id.
27
- */
28
- export declare function uniqueId(): number;
29
- /**
30
- * Given a destination object and optionally many source objects,
31
- * copy all properties from the source objects into the destination.
32
- * The last source object given overrides properties from previous
33
- * source objects.
34
- *
35
- * @param dest - destination object
36
- * @param sources - sources from which properties are pulled
37
- */
38
- export declare function extend<T extends {}, U>(dest: T, source: U): T & U;
39
- export declare function extend<T extends {}, U, V>(dest: T, source1: U, source2: V): T & U & V;
40
- export declare function extend<T extends {}, U, V, W>(dest: T, source1: U, source2: V, source3: W): T & U & V & W;
41
- export declare function extend(dest: Record<string, any>, ...sources: Array<any>): any;
42
- type KeysOfUnion<T> = T extends T ? keyof T : never;
43
- /**
44
- * Given an object and a number of properties as strings, return version
45
- * of that object with only those properties.
46
- *
47
- * @param src - the object
48
- * @param properties - an array of property names chosen
49
- * to appear on the resulting object.
50
- * @returns object with limited properties.
51
- * @example
52
- * ```ts
53
- * let foo = { name: 'Charlie', age: 10 };
54
- * let justName = pick(foo, ['name']); // justName = { name: 'Charlie' }
55
- * ```
56
- */
57
- export declare function pick<T extends object>(src: T, properties: Array<KeysOfUnion<T>>): Partial<T>;
58
- /**
59
- * Makes optional keys required and add the the undefined type.
60
- *
61
- * ```
62
- * interface Test {
63
- * foo: number;
64
- * bar?: number;
65
- * baz: number | undefined;
66
- * }
67
- *
68
- * Complete<Test> {
69
- * foo: number;
70
- * bar: number | undefined;
71
- * baz: number | undefined;
72
- * }
73
- *
74
- * ```
75
- *
76
- * See https://medium.com/terria/typescript-transforming-optional-properties-to-required-properties-that-may-be-undefined-7482cb4e1585
77
- */
78
- export type Complete<T> = {
79
- [P in keyof Required<T>]: Pick<T, P> extends Required<Pick<T, P>> ? T[P] : T[P] | undefined;
80
- };
81
- /**
82
- * Given given (x, y), (x1, y1) control points for a bezier curve,
83
- * return a function that interpolates along that curve.
84
- *
85
- * @param p1x - control point 1 x coordinate
86
- * @param p1y - control point 1 y coordinate
87
- * @param p2x - control point 2 x coordinate
88
- * @param p2y - control point 2 y coordinate
89
- */
90
- export declare function bezier(p1x: number, p1y: number, p2x: number, p2y: number): (t: number) => number;
91
- /**
92
- * A default bezier-curve powered easing function with
93
- * control points (0.25, 0.1) and (0.25, 1)
94
- */
95
- export declare const defaultEasing: (t: number) => number;
96
- export declare function warnOnce(message: string): void;
97
- /**
98
- * This method converts degrees to radians.
99
- * The return value is the radian value.
100
- * @param degrees - The number of degrees
101
- * @returns radians
102
- */
103
- export declare function degreesToRadians(degrees: number): number;
104
- export {};
@@ -1,155 +0,0 @@
1
- import UnitBezier from '@mapbox/unitbezier';
2
- export const interpolates = {
3
- number: function number(from, to, t) {
4
- return from + t * (to - from);
5
- }
6
- };
7
-
8
- /**
9
- * constrain n to the given range via min + max
10
- *
11
- * @param n - value
12
- * @param min - the minimum value to be returned
13
- * @param max - the maximum value to be returned
14
- * @returns the clamped value
15
- */
16
- export function clamp(n, min, max) {
17
- return Math.min(max, Math.max(min, n));
18
- }
19
-
20
- /**
21
- * constrain n to the given range, excluding the minimum, via modular arithmetic
22
- *
23
- * @param n - value
24
- * @param min - the minimum value to be returned, exclusive
25
- * @param max - the maximum value to be returned, inclusive
26
- * @returns constrained number
27
- */
28
- export function wrap(n, min, max) {
29
- const d = max - min;
30
- const w = ((n - min) % d + d) % d + min;
31
- return w === min ? max : w;
32
- }
33
- let id = 1;
34
-
35
- /**
36
- * Return a unique numeric id, starting at 1 and incrementing with
37
- * each call.
38
- *
39
- * @returns unique numeric id.
40
- */
41
- export function uniqueId() {
42
- return id++;
43
- }
44
-
45
- /**
46
- * Given a destination object and optionally many source objects,
47
- * copy all properties from the source objects into the destination.
48
- * The last source object given overrides properties from previous
49
- * source objects.
50
- *
51
- * @param dest - destination object
52
- * @param sources - sources from which properties are pulled
53
- */
54
-
55
- export function extend(dest, ...sources) {
56
- for (const src of sources) {
57
- for (const k in src) {
58
- dest[k] = src[k];
59
- }
60
- }
61
- return dest;
62
- }
63
-
64
- // See https://stackoverflow.com/questions/49401866/all-possible-keys-of-an-union-type
65
-
66
- /**
67
- * Given an object and a number of properties as strings, return version
68
- * of that object with only those properties.
69
- *
70
- * @param src - the object
71
- * @param properties - an array of property names chosen
72
- * to appear on the resulting object.
73
- * @returns object with limited properties.
74
- * @example
75
- * ```ts
76
- * let foo = { name: 'Charlie', age: 10 };
77
- * let justName = pick(foo, ['name']); // justName = { name: 'Charlie' }
78
- * ```
79
- */
80
- export function pick(src, properties) {
81
- const result = {};
82
- for (let i = 0; i < properties.length; i++) {
83
- const k = properties[i];
84
- if (k in src) {
85
- result[k] = src[k];
86
- }
87
- }
88
- return result;
89
- }
90
-
91
- /**
92
- * Makes optional keys required and add the the undefined type.
93
- *
94
- * ```
95
- * interface Test {
96
- * foo: number;
97
- * bar?: number;
98
- * baz: number | undefined;
99
- * }
100
- *
101
- * Complete<Test> {
102
- * foo: number;
103
- * bar: number | undefined;
104
- * baz: number | undefined;
105
- * }
106
- *
107
- * ```
108
- *
109
- * See https://medium.com/terria/typescript-transforming-optional-properties-to-required-properties-that-may-be-undefined-7482cb4e1585
110
- */
111
-
112
- /**
113
- * Given given (x, y), (x1, y1) control points for a bezier curve,
114
- * return a function that interpolates along that curve.
115
- *
116
- * @param p1x - control point 1 x coordinate
117
- * @param p1y - control point 1 y coordinate
118
- * @param p2x - control point 2 x coordinate
119
- * @param p2y - control point 2 y coordinate
120
- */
121
- export function bezier(p1x, p1y, p2x, p2y) {
122
- const bezier = new UnitBezier(p1x, p1y, p2x, p2y);
123
- return t => {
124
- return bezier.solve(t);
125
- };
126
- }
127
-
128
- /**
129
- * A default bezier-curve powered easing function with
130
- * control points (0.25, 0.1) and (0.25, 1)
131
- */
132
- export const defaultEasing = bezier(0.25, 0.1, 0.25, 1);
133
-
134
- /**
135
- * Print a warning message to the console and ensure duplicate warning messages
136
- * are not printed.
137
- */
138
- const warnOnceHistory = {};
139
- export function warnOnce(message) {
140
- if (!warnOnceHistory[message]) {
141
- // console isn't defined in some WebWorkers, see #2558
142
- if (typeof console !== 'undefined') console.warn(message);
143
- warnOnceHistory[message] = true;
144
- }
145
- }
146
-
147
- /**
148
- * This method converts degrees to radians.
149
- * The return value is the radian value.
150
- * @param degrees - The number of degrees
151
- * @returns radians
152
- */
153
- export function degreesToRadians(degrees) {
154
- return degrees * Math.PI / 180;
155
- }
package/lib/index.d.ts DELETED
@@ -1,5 +0,0 @@
1
- export { MapMouseEvent } from './map/events';
2
- export { MercatorCoordinate } from './map/geo/mercator_coordinate';
3
- export { Map } from './map/map';
4
- export type { MapOptions } from './map/map';
5
- export { SimpleMapCoord, type ISimpleMapCoord } from './map/util/simpleMapCoord';
package/lib/index.js DELETED
@@ -1,33 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- Object.defineProperty(exports, "Map", {
7
- enumerable: true,
8
- get: function () {
9
- return _map.Map;
10
- }
11
- });
12
- Object.defineProperty(exports, "MapMouseEvent", {
13
- enumerable: true,
14
- get: function () {
15
- return _events.MapMouseEvent;
16
- }
17
- });
18
- Object.defineProperty(exports, "MercatorCoordinate", {
19
- enumerable: true,
20
- get: function () {
21
- return _mercator_coordinate.MercatorCoordinate;
22
- }
23
- });
24
- Object.defineProperty(exports, "SimpleMapCoord", {
25
- enumerable: true,
26
- get: function () {
27
- return _simpleMapCoord.SimpleMapCoord;
28
- }
29
- });
30
- var _events = require("./map/events");
31
- var _mercator_coordinate = require("./map/geo/mercator_coordinate");
32
- var _map = require("./map/map");
33
- var _simpleMapCoord = require("./map/util/simpleMapCoord");