@mailwoman/spatial 4.16.2 → 5.1.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.
- package/bbox.ts +5 -7
- package/coordinate-formats.test.ts +1 -0
- package/coordinate-formats.ts +21 -7
- package/countries/names.ts +1 -1
- package/geometries/point.ts +12 -10
- package/geometries/polygon.test.ts +1 -0
- package/geometries/polygon.ts +33 -35
- package/google/place-id.ts +2 -2
- package/h3/index.ts +1 -0
- package/objects.ts +7 -8
- package/out/bbox.d.ts +5 -7
- package/out/bbox.d.ts.map +1 -1
- package/out/bbox.js +4 -5
- package/out/bbox.js.map +1 -1
- package/out/coordinate-formats.d.ts +6 -5
- package/out/coordinate-formats.d.ts.map +1 -1
- package/out/coordinate-formats.js +7 -7
- package/out/coordinate-formats.js.map +1 -1
- package/out/countries/names.d.ts +1 -1
- package/out/countries/names.js +1 -1
- package/out/geometries/point.d.ts +5 -10
- package/out/geometries/point.d.ts.map +1 -1
- package/out/geometries/point.js +2 -4
- package/out/geometries/point.js.map +1 -1
- package/out/geometries/polygon.d.ts +32 -35
- package/out/geometries/polygon.d.ts.map +1 -1
- package/out/geometries/polygon.js.map +1 -1
- package/out/google/place-id.d.ts +2 -2
- package/out/h3/index.d.ts.map +1 -1
- package/out/h3/index.js.map +1 -1
- package/out/objects.d.ts +7 -8
- package/out/objects.d.ts.map +1 -1
- package/out/objects.js.map +1 -1
- package/out/position.d.ts +10 -12
- package/out/position.d.ts.map +1 -1
- package/out/position.js +8 -10
- package/out/position.js.map +1 -1
- package/out/sdk/well-known-text.d.ts +3 -0
- package/out/sdk/well-known-text.d.ts.map +1 -1
- package/out/sdk/well-known-text.js +3 -0
- package/out/sdk/well-known-text.js.map +1 -1
- package/out/tsconfig.tsbuildinfo +1 -1
- package/package.json +10 -10
- package/position.ts +10 -11
- package/sdk/well-known-text.test.ts +1 -0
- package/sdk/well-known-text.ts +3 -0
package/bbox.ts
CHANGED
|
@@ -54,8 +54,7 @@ export type BBox2DLiteral = [
|
|
|
54
54
|
]
|
|
55
55
|
|
|
56
56
|
/**
|
|
57
|
-
* A 3-dimensional rectangular area that can be determined by two longitudes, two latitudes, and two
|
|
58
|
-
* altitudes.
|
|
57
|
+
* A 3-dimensional rectangular area that can be determined by two longitudes, two latitudes, and two altitudes.
|
|
59
58
|
*
|
|
60
59
|
* @category GeoJSON
|
|
61
60
|
* @category Bounding Box
|
|
@@ -145,9 +144,8 @@ export function isBBox(input: unknown): input is BBox2DLiteral | BBox3DLiteral {
|
|
|
145
144
|
/**
|
|
146
145
|
* Type-predicate to determine if the given input is a GeoBoundingBox instance.
|
|
147
146
|
*
|
|
148
|
-
* Note that this function only checks if the input is an instance of the GeoBoundingBox class.
|
|
149
|
-
*
|
|
150
|
-
* caution.
|
|
147
|
+
* Note that this function only checks if the input is an instance of the GeoBoundingBox class. `instanceof` checks are
|
|
148
|
+
* not reliable in JavaScript, so this function should be used with caution.
|
|
151
149
|
*
|
|
152
150
|
* @category GeoJSON
|
|
153
151
|
*/
|
|
@@ -167,8 +165,8 @@ export type GeoBoundingBoxInput = BBox2DLiteral | BBox3DLiteral | GeoBoundingBox
|
|
|
167
165
|
/**
|
|
168
166
|
* A bounding box to represent the coordinate range of a GeoJSON object.
|
|
169
167
|
*
|
|
170
|
-
* This is useful when defining the extent of a GeoJSON object, such as the minimum and maximum
|
|
171
|
-
*
|
|
168
|
+
* This is useful when defining the extent of a GeoJSON object, such as the minimum and maximum coordinates of the
|
|
169
|
+
* object's Geometries, Features, or Feature Collections.
|
|
172
170
|
*/
|
|
173
171
|
export class GeoBoundingBox {
|
|
174
172
|
//#region Properties
|
package/coordinate-formats.ts
CHANGED
|
@@ -15,8 +15,7 @@ const toRad = (d: number): number => (d * Math.PI) / 180
|
|
|
15
15
|
const toDeg = (r: number): number => (r * 180) / Math.PI
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
|
-
* Render a single signed degree as `D° M′ S″ H` with the given hemisphere letters `[positive,
|
|
19
|
-
* negative]`.
|
|
18
|
+
* Render a single signed degree as `D° M′ S″ H` with the given hemisphere letters `[positive, negative]`.
|
|
20
19
|
*/
|
|
21
20
|
function dmsComponent(value: number, hemispheres: [string, string], secondsDp = 2): string {
|
|
22
21
|
const hemisphere = value >= 0 ? hemispheres[0] : hemispheres[1]
|
|
@@ -25,6 +24,7 @@ function dmsComponent(value: number, hemispheres: [string, string], secondsDp =
|
|
|
25
24
|
const minutesFull = (abs - degrees) * 60
|
|
26
25
|
const minutes = Math.floor(minutesFull)
|
|
27
26
|
const seconds = (minutesFull - minutes) * 60
|
|
27
|
+
|
|
28
28
|
return `${degrees}° ${minutes}′ ${seconds.toFixed(secondsDp)}″ ${hemisphere}`
|
|
29
29
|
}
|
|
30
30
|
|
|
@@ -38,6 +38,7 @@ const WEB_MERCATOR_R = 6378137
|
|
|
38
38
|
/** Web Mercator (EPSG:3857) projection of a coordinate. */
|
|
39
39
|
export function toMercator(lat: number, lon: number): { x: number; y: number } {
|
|
40
40
|
const clampedLat = Math.max(-85.05112878, Math.min(85.05112878, lat))
|
|
41
|
+
|
|
41
42
|
return {
|
|
42
43
|
x: WEB_MERCATOR_R * toRad(lon),
|
|
43
44
|
y: WEB_MERCATOR_R * Math.log(Math.tan(Math.PI / 4 + toRad(clampedLat) / 2)),
|
|
@@ -53,6 +54,7 @@ export function qiblaBearing(lat: number, lon: number): number {
|
|
|
53
54
|
const dLon = toRad(KAABA.lon - lon)
|
|
54
55
|
const y = Math.sin(dLon)
|
|
55
56
|
const x = Math.cos(phi1) * Math.tan(phi2) - Math.sin(phi1) * Math.cos(dLon)
|
|
57
|
+
|
|
56
58
|
return (toDeg(Math.atan2(y, x)) + 360) % 360
|
|
57
59
|
}
|
|
58
60
|
|
|
@@ -72,6 +74,7 @@ export function toGeohash(lat: number, lon: number, precision = 9): string {
|
|
|
72
74
|
while (hash.length < precision) {
|
|
73
75
|
if (evenBit) {
|
|
74
76
|
const mid = (lonMin + lonMax) / 2
|
|
77
|
+
|
|
75
78
|
if (lon >= mid) {
|
|
76
79
|
bits = bits * 2 + 1
|
|
77
80
|
lonMin = mid
|
|
@@ -81,6 +84,7 @@ export function toGeohash(lat: number, lon: number, precision = 9): string {
|
|
|
81
84
|
}
|
|
82
85
|
} else {
|
|
83
86
|
const mid = (latMin + latMax) / 2
|
|
87
|
+
|
|
84
88
|
if (lat >= mid) {
|
|
85
89
|
bits = bits * 2 + 1
|
|
86
90
|
latMin = mid
|
|
@@ -90,12 +94,14 @@ export function toGeohash(lat: number, lon: number, precision = 9): string {
|
|
|
90
94
|
}
|
|
91
95
|
}
|
|
92
96
|
evenBit = !evenBit
|
|
97
|
+
|
|
93
98
|
if (++bit === 5) {
|
|
94
99
|
hash += GEOHASH_BASE32[bits]
|
|
95
100
|
bit = 0
|
|
96
101
|
bits = 0
|
|
97
102
|
}
|
|
98
103
|
}
|
|
104
|
+
|
|
99
105
|
return hash
|
|
100
106
|
}
|
|
101
107
|
|
|
@@ -113,6 +119,7 @@ export function toMaidenhead(lat: number, lon: number, pairs = 3): string {
|
|
|
113
119
|
String.fromCharCode(A_CODE + Math.floor((lonAdj % 2) * 12)).toLowerCase(),
|
|
114
120
|
String.fromCharCode(A_CODE + Math.floor((latAdj % 1) * 24)).toLowerCase(),
|
|
115
121
|
]
|
|
122
|
+
|
|
116
123
|
return out.slice(0, pairs * 2).join("")
|
|
117
124
|
}
|
|
118
125
|
|
|
@@ -120,9 +127,9 @@ const J2000 = 2451545.0
|
|
|
120
127
|
const unixEpochJulian = 2440587.5
|
|
121
128
|
|
|
122
129
|
/**
|
|
123
|
-
* Sunrise / solar-noon / sunset for a coordinate on a date, as UTC epoch seconds, via the standard
|
|
124
|
-
*
|
|
125
|
-
*
|
|
130
|
+
* Sunrise / solar-noon / sunset for a coordinate on a date, as UTC epoch seconds, via the standard sunrise equation.
|
|
131
|
+
* `rise` and `set` are absent during polar day or polar night (the sun never crosses the horizon); `noon` (solar
|
|
132
|
+
* transit) is always present.
|
|
126
133
|
*/
|
|
127
134
|
export function sunTimes(
|
|
128
135
|
lat: number,
|
|
@@ -143,8 +150,10 @@ export function sunTimes(
|
|
|
143
150
|
(Math.sin(toRad(-0.833)) - Math.sin(latR) * Math.sin(declination)) / (Math.cos(latR) * Math.cos(declination))
|
|
144
151
|
const toEpoch = (j: number): number => Math.round((j - unixEpochJulian) * 86400)
|
|
145
152
|
const noon = toEpoch(transit)
|
|
153
|
+
|
|
146
154
|
if (cosH >= 1 || cosH <= -1) return { noon }
|
|
147
155
|
const hourAngle = toDeg(Math.acos(cosH))
|
|
156
|
+
|
|
148
157
|
return { rise: toEpoch(transit - hourAngle / 360), set: toEpoch(transit + hourAngle / 360), noon }
|
|
149
158
|
}
|
|
150
159
|
|
|
@@ -180,7 +189,9 @@ function latLonToUtm(lat: number, lon: number): { zone: number; easting: number;
|
|
|
180
189
|
(A ** 2 / 2 +
|
|
181
190
|
((5 - T + 9 * C + 4 * C ** 2) * A ** 4) / 24 +
|
|
182
191
|
((61 - 58 * T + T ** 2 + 600 * C - 330 * UTM_EP2) * A ** 6) / 720))
|
|
192
|
+
|
|
183
193
|
if (lat < 0) northing += 10000000
|
|
194
|
+
|
|
184
195
|
return { zone, easting, northing }
|
|
185
196
|
}
|
|
186
197
|
|
|
@@ -188,18 +199,21 @@ const MGRS_LAT_BANDS = "CDEFGHJKLMNPQRSTUVWX"
|
|
|
188
199
|
const MGRS_COL_SETS = ["ABCDEFGH", "JKLMNPQR", "STUVWXYZ"]
|
|
189
200
|
const MGRS_ROW_LETTERS = "ABCDEFGHJKLMNPQRSTUV"
|
|
190
201
|
|
|
191
|
-
/**
|
|
192
|
-
(±80°/84°).
|
|
202
|
+
/**
|
|
203
|
+
* Military Grid Reference System for a coordinate (`"18SUJ2340806479"`); `""` outside MGRS bands (±80°/84°).
|
|
204
|
+
*/
|
|
193
205
|
export function toMGRS(lat: number, lon: number): string {
|
|
194
206
|
if (lat < -80 || lat > 84) return ""
|
|
195
207
|
const band = MGRS_LAT_BANDS[Math.floor((lat + 80) / 8)]!
|
|
196
208
|
const { zone, easting, northing } = latLonToUtm(lat, lon)
|
|
197
209
|
const colLetter = MGRS_COL_SETS[(zone - 1) % 3]![Math.floor(easting / 100000) - 1]!
|
|
198
210
|
let row = Math.floor(northing / 100000) % 20
|
|
211
|
+
|
|
199
212
|
if (zone % 2 === 0) row = (row + 5) % 20
|
|
200
213
|
const rowLetter = MGRS_ROW_LETTERS[row]!
|
|
201
214
|
const e = String(Math.floor(easting % 100000)).padStart(5, "0")
|
|
202
215
|
const n = String(Math.floor(northing % 100000)).padStart(5, "0")
|
|
216
|
+
|
|
203
217
|
return `${zone}${band}${colLetter}${rowLetter}${e}${n}`
|
|
204
218
|
}
|
|
205
219
|
|
package/countries/names.ts
CHANGED
package/geometries/point.ts
CHANGED
|
@@ -9,6 +9,7 @@ import type { LatLng, LatLngLiteral } from "@googlemaps/google-maps-services-js"
|
|
|
9
9
|
import { tryParsingJSON } from "@mailwoman/core/objects"
|
|
10
10
|
import { convert as convertCoords } from "geo-coordinates-parser"
|
|
11
11
|
import { latLngToCell } from "h3-js"
|
|
12
|
+
|
|
12
13
|
import { type BBox2DLiteral, type BBox3DLiteral, GeoBoundingBox, isBBox } from "../bbox.js"
|
|
13
14
|
import { type H3Cell, shortenH3Cell } from "../h3/index.js"
|
|
14
15
|
import { type GeoObjectLiteral, GeometryType } from "../objects.js"
|
|
@@ -25,8 +26,7 @@ import {
|
|
|
25
26
|
} from "../position.js"
|
|
26
27
|
|
|
27
28
|
/**
|
|
28
|
-
* A JSON-serializeable single point geometry, such as a specific location, address, or longitude,
|
|
29
|
-
* latitude pair.
|
|
29
|
+
* A JSON-serializeable single point geometry, such as a specific location, address, or longitude, latitude pair.
|
|
30
30
|
*
|
|
31
31
|
* ```js
|
|
32
32
|
* {
|
|
@@ -58,7 +58,9 @@ export function isPointLiteral(input: PointLiteral | null | undefined | unknown)
|
|
|
58
58
|
if (!input || typeof input !== "object") return false
|
|
59
59
|
|
|
60
60
|
if (!("type" in input)) return false
|
|
61
|
+
|
|
61
62
|
if (!("coordinates" in input)) return false
|
|
63
|
+
|
|
62
64
|
if (input.type !== GeometryType.Point) return false
|
|
63
65
|
|
|
64
66
|
return isCoordPairLiteral(input.coordinates)
|
|
@@ -76,14 +78,15 @@ export interface GeolocationCoordinatesLike {
|
|
|
76
78
|
}
|
|
77
79
|
|
|
78
80
|
/**
|
|
79
|
-
* Type-predicate to determine if the given input appears to be a {@linkcode GeolocationCoordinates}
|
|
80
|
-
* object.
|
|
81
|
+
* Type-predicate to determine if the given input appears to be a {@linkcode GeolocationCoordinates} object.
|
|
81
82
|
*/
|
|
82
83
|
export function isGeolocationCoordinatesLike(input: unknown): input is GeolocationCoordinatesLike {
|
|
83
84
|
if (!input || typeof input !== "object") return false
|
|
84
85
|
|
|
85
86
|
if (!("latitude" in input)) return false
|
|
87
|
+
|
|
86
88
|
if (!("longitude" in input)) return false
|
|
89
|
+
|
|
87
90
|
if (!("altitude" in input)) return false
|
|
88
91
|
|
|
89
92
|
return true
|
|
@@ -223,8 +226,7 @@ export class GeoPoint implements PointLiteral {
|
|
|
223
226
|
constructor(geoLocationCoordinates: GeolocationCoordinatesLike, bbox?: BBox2DLiteral | BBox3DLiteral | GeoBoundingBox)
|
|
224
227
|
|
|
225
228
|
/**
|
|
226
|
-
* Creates a new GeoPoint instance from a Google Maps API
|
|
227
|
-
* {@linkcode google.LatLngLiteral | LatLngLiteral} object.
|
|
229
|
+
* Creates a new GeoPoint instance from a Google Maps API {@linkcode google.LatLngLiteral | LatLngLiteral} object.
|
|
228
230
|
*/
|
|
229
231
|
constructor(latLngLiteral: google.LatLngLiteral, bbox?: BBox2DLiteral | BBox3DLiteral | GeoBoundingBox)
|
|
230
232
|
|
|
@@ -233,8 +235,7 @@ export class GeoPoint implements PointLiteral {
|
|
|
233
235
|
*/
|
|
234
236
|
constructor(interpolatedCoords: InternalPointCoordinates, bbox?: BBox2DLiteral | BBox3DLiteral | GeoBoundingBox)
|
|
235
237
|
/**
|
|
236
|
-
* Creates a new GeoPoint instance from a Google Maps API {@linkcode google.LatLng | LatLng}
|
|
237
|
-
* object.
|
|
238
|
+
* Creates a new GeoPoint instance from a Google Maps API {@linkcode google.LatLng | LatLng} object.
|
|
238
239
|
*/
|
|
239
240
|
constructor(latLng: LatLngLiteral, bbox?: BBox2DLiteral | BBox3DLiteral | GeoBoundingBox)
|
|
240
241
|
/**
|
|
@@ -283,6 +284,7 @@ export class GeoPoint implements PointLiteral {
|
|
|
283
284
|
*/
|
|
284
285
|
static from(input: unknown): GeoPoint | null {
|
|
285
286
|
if (!input) return null
|
|
287
|
+
|
|
286
288
|
if (input instanceof GeoPoint) return input
|
|
287
289
|
|
|
288
290
|
if (typeof input === "string") {
|
|
@@ -295,6 +297,7 @@ export class GeoPoint implements PointLiteral {
|
|
|
295
297
|
|
|
296
298
|
try {
|
|
297
299
|
const point = new GeoPoint(input as GeoPointInput)
|
|
300
|
+
|
|
298
301
|
if (point.isNullIsland()) return null
|
|
299
302
|
|
|
300
303
|
return point
|
|
@@ -348,8 +351,7 @@ export class GeoPoint implements PointLiteral {
|
|
|
348
351
|
}
|
|
349
352
|
|
|
350
353
|
/**
|
|
351
|
-
* Converts the GeoPoint to a Google Maps API {@linkcode google.LatLngLiteral | LatLngLiteral}
|
|
352
|
-
* object.
|
|
354
|
+
* Converts the GeoPoint to a Google Maps API {@linkcode google.LatLngLiteral | LatLngLiteral} object.
|
|
353
355
|
*/
|
|
354
356
|
public toGoogleLatLngLiteral(): google.LatLngLiteral {
|
|
355
357
|
return {
|
package/geometries/polygon.ts
CHANGED
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
7
|
import { ResourceError } from "@mailwoman/core/errors"
|
|
8
|
+
|
|
8
9
|
import type { GeoObjectLiteral } from "../objects.js"
|
|
9
10
|
import type { LineStringPath } from "./line-string.js"
|
|
10
11
|
|
|
@@ -12,23 +13,22 @@ import type { LineStringPath } from "./line-string.js"
|
|
|
12
13
|
* An array of positions forming a closed shape, such as a country or a lake.
|
|
13
14
|
*
|
|
14
15
|
* @example
|
|
16
|
+
* A polygon without holes:
|
|
15
17
|
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* ```json
|
|
19
|
-
* {
|
|
18
|
+
* ```json
|
|
19
|
+
* {
|
|
20
20
|
* "type": "Polygon",
|
|
21
21
|
* "coordinates": [
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
22
|
+
* [
|
|
23
|
+
* [100, 0],
|
|
24
|
+
* [101, 0],
|
|
25
|
+
* [101, 1],
|
|
26
|
+
* [100, 1],
|
|
27
|
+
* [100, 0]
|
|
28
|
+
* ]
|
|
29
29
|
* ]
|
|
30
|
-
*
|
|
31
|
-
*
|
|
30
|
+
* }
|
|
31
|
+
* ```
|
|
32
32
|
*/
|
|
33
33
|
export type SolidPolygonPath = [
|
|
34
34
|
/**
|
|
@@ -39,34 +39,32 @@ export type SolidPolygonPath = [
|
|
|
39
39
|
]
|
|
40
40
|
|
|
41
41
|
/**
|
|
42
|
-
* An array of positions forming a closed shape with holes, such as a country with islands or a lake
|
|
43
|
-
* with islands.
|
|
42
|
+
* An array of positions forming a closed shape with holes, such as a country with islands or a lake with islands.
|
|
44
43
|
*
|
|
45
44
|
* @example
|
|
45
|
+
* A polygon with holes:
|
|
46
46
|
*
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
* ```json
|
|
50
|
-
* {
|
|
47
|
+
* ```json
|
|
48
|
+
* {
|
|
51
49
|
* "type": "Polygon",
|
|
52
50
|
* "coordinates": [
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
*
|
|
66
|
-
*
|
|
51
|
+
* [
|
|
52
|
+
* [100.0, 0.0],
|
|
53
|
+
* [101.0, 0.0],
|
|
54
|
+
* [101.0, 1.0],
|
|
55
|
+
* [100.0, 1.0],
|
|
56
|
+
* [100.0, 0.0]
|
|
57
|
+
* ],
|
|
58
|
+
* [
|
|
59
|
+
* [100.8, 0.8],
|
|
60
|
+
* [100.8, 0.2],
|
|
61
|
+
* [100.2, 0.2],
|
|
62
|
+
* [100.2, 0.8],
|
|
63
|
+
* [100.8, 0.8]
|
|
64
|
+
* ]
|
|
67
65
|
* ]
|
|
68
|
-
*
|
|
69
|
-
*
|
|
66
|
+
* }
|
|
67
|
+
* ```
|
|
70
68
|
*/
|
|
71
69
|
export type NestedPolygonPath = [
|
|
72
70
|
/**
|
package/google/place-id.ts
CHANGED
|
@@ -11,8 +11,8 @@ import type { Tagged } from "type-fest"
|
|
|
11
11
|
/**
|
|
12
12
|
* A Place ID uniquely identifies a place in the Google Places database and on Google Maps.
|
|
13
13
|
*
|
|
14
|
-
* The length of the identifier may vary. Generally, the identifier is a 27-character string,
|
|
15
|
-
*
|
|
14
|
+
* The length of the identifier may vary. Generally, the identifier is a 27-character string, however, more specific
|
|
15
|
+
* places may have longer identifiers.
|
|
16
16
|
*
|
|
17
17
|
* Place IDs appear to be base64-encoded strings, delimited by underscores and dashes.
|
|
18
18
|
*
|
package/h3/index.ts
CHANGED
package/objects.ts
CHANGED
|
@@ -36,12 +36,12 @@ export const GeometryType = {
|
|
|
36
36
|
/**
|
|
37
37
|
* The base GeoJSON object.
|
|
38
38
|
*
|
|
39
|
-
* The GeoJSON specification also allows foreign members
|
|
40
|
-
*
|
|
39
|
+
* The GeoJSON specification also allows foreign members (https://tools.ietf.org/html/rfc7946#section-6.1) to be
|
|
40
|
+
* included in the object.
|
|
41
41
|
*
|
|
42
|
-
* @see {@link https://tools.ietf.org/html/rfc7946#section-3 GeoJSON Object}
|
|
43
42
|
* @title Geo Object
|
|
44
43
|
* @public
|
|
44
|
+
* @see {@link https://tools.ietf.org/html/rfc7946#section-3 GeoJSON Object}
|
|
45
45
|
*/
|
|
46
46
|
export interface GeoObjectLiteral {
|
|
47
47
|
/**
|
|
@@ -55,11 +55,10 @@ export interface GeoObjectLiteral {
|
|
|
55
55
|
id?: string | number | undefined | null
|
|
56
56
|
|
|
57
57
|
/**
|
|
58
|
-
* A bounding box of the coordinate range of the object's Geometries, Features, or Feature
|
|
59
|
-
* Collections.
|
|
58
|
+
* A bounding box of the coordinate range of the object's Geometries, Features, or Feature Collections.
|
|
60
59
|
*
|
|
61
|
-
* This is useful when defining the extent of a GeoJSON object, i.e. the minimum and maximum
|
|
62
|
-
*
|
|
60
|
+
* This is useful when defining the extent of a GeoJSON object, i.e. the minimum and maximum coordinates of the
|
|
61
|
+
* object's Geometries, Features, or Feature Collections.
|
|
63
62
|
*
|
|
64
63
|
* @see {@link https://tools.ietf.org/html/rfc7946#section-5 GeoJSON Bounding Boxes}
|
|
65
64
|
*/
|
|
@@ -68,8 +67,8 @@ export interface GeoObjectLiteral {
|
|
|
68
67
|
/**
|
|
69
68
|
* Coordinate reference system for GeoJSON objects.
|
|
70
69
|
*
|
|
71
|
-
* @see {@link https://tools.ietf.org/html/rfc7946#section-4 Coordinate Reference Systems}
|
|
72
70
|
* @title Coordinate Reference System
|
|
71
|
+
* @see {@link https://tools.ietf.org/html/rfc7946#section-4 Coordinate Reference Systems}
|
|
73
72
|
*/
|
|
74
73
|
crs?: {
|
|
75
74
|
type: "name"
|
package/out/bbox.d.ts
CHANGED
|
@@ -48,8 +48,7 @@ export type BBox2DLiteral = [
|
|
|
48
48
|
maxLatitude: number
|
|
49
49
|
];
|
|
50
50
|
/**
|
|
51
|
-
* A 3-dimensional rectangular area that can be determined by two longitudes, two latitudes, and two
|
|
52
|
-
* altitudes.
|
|
51
|
+
* A 3-dimensional rectangular area that can be determined by two longitudes, two latitudes, and two altitudes.
|
|
53
52
|
*
|
|
54
53
|
* @category GeoJSON
|
|
55
54
|
* @category Bounding Box
|
|
@@ -123,9 +122,8 @@ export declare function isBBox(input: unknown): input is BBox2DLiteral | BBox3DL
|
|
|
123
122
|
/**
|
|
124
123
|
* Type-predicate to determine if the given input is a GeoBoundingBox instance.
|
|
125
124
|
*
|
|
126
|
-
* Note that this function only checks if the input is an instance of the GeoBoundingBox class.
|
|
127
|
-
*
|
|
128
|
-
* caution.
|
|
125
|
+
* Note that this function only checks if the input is an instance of the GeoBoundingBox class. `instanceof` checks are
|
|
126
|
+
* not reliable in JavaScript, so this function should be used with caution.
|
|
129
127
|
*
|
|
130
128
|
* @category GeoJSON
|
|
131
129
|
*/
|
|
@@ -137,8 +135,8 @@ export type GeoBoundingBoxInput = BBox2DLiteral | BBox3DLiteral | GeoBoundingBox
|
|
|
137
135
|
/**
|
|
138
136
|
* A bounding box to represent the coordinate range of a GeoJSON object.
|
|
139
137
|
*
|
|
140
|
-
* This is useful when defining the extent of a GeoJSON object, such as the minimum and maximum
|
|
141
|
-
*
|
|
138
|
+
* This is useful when defining the extent of a GeoJSON object, such as the minimum and maximum coordinates of the
|
|
139
|
+
* object's Geometries, Features, or Feature Collections.
|
|
142
140
|
*/
|
|
143
141
|
export declare class GeoBoundingBox {
|
|
144
142
|
#private;
|
package/out/bbox.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bbox.d.ts","sourceRoot":"","sources":["../bbox.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAoB,MAAM,yBAAyB,CAAA;AAE/E,OAAO,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAA;AAItD;;;;;;;;;GASG;AACH,MAAM,MAAM,aAAa,GAAG;IAC3B;;;;;OAKG;IACH,YAAY,EAAE,MAAM;IACpB;;;;;OAKG;IACH,WAAW,EAAE,MAAM;IACnB;;;;;OAKG;IACH,YAAY,EAAE,MAAM;IACpB;;;;;OAKG;IACH,WAAW,EA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AU,CAAC,EAAE,oBAAoB;gBAEtD,KAAK,CAAC,EAAE,mBAAmB,EAAE,UAAU,CAAC,EAAE,oBAAoB;IAmCnE,IAAI;IAIJ,IAAI;IAQX;;OAEG;IACI,QAAQ,IAAI,aAAa;IAUhC;;OAEG;IACI,QAAQ,IAAI,aAAa;IAYzB,MAAM,IAAI,aAAa,GAAG,aAAa;IAM9C;;OAEG;IACI,WAAW,IAAI,cAAc;IAepC;;;;OAIG;IACI,QAAQ,IAAI,MAAM;CAOzB"}
|
package/out/bbox.js
CHANGED
|
@@ -43,9 +43,8 @@ export function isBBox(input) {
|
|
|
43
43
|
/**
|
|
44
44
|
* Type-predicate to determine if the given input is a GeoBoundingBox instance.
|
|
45
45
|
*
|
|
46
|
-
* Note that this function only checks if the input is an instance of the GeoBoundingBox class.
|
|
47
|
-
*
|
|
48
|
-
* caution.
|
|
46
|
+
* Note that this function only checks if the input is an instance of the GeoBoundingBox class. `instanceof` checks are
|
|
47
|
+
* not reliable in JavaScript, so this function should be used with caution.
|
|
49
48
|
*
|
|
50
49
|
* @category GeoJSON
|
|
51
50
|
*/
|
|
@@ -56,8 +55,8 @@ export function isGeoBoundingBox(input) {
|
|
|
56
55
|
/**
|
|
57
56
|
* A bounding box to represent the coordinate range of a GeoJSON object.
|
|
58
57
|
*
|
|
59
|
-
* This is useful when defining the extent of a GeoJSON object, such as the minimum and maximum
|
|
60
|
-
*
|
|
58
|
+
* This is useful when defining the extent of a GeoJSON object, such as the minimum and maximum coordinates of the
|
|
59
|
+
* object's Geometries, Features, or Feature Collections.
|
|
61
60
|
*/
|
|
62
61
|
export class GeoBoundingBox {
|
|
63
62
|
//#region Properties
|
package/out/bbox.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bbox.js","sourceRoot":"","sources":["../bbox.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,eAAe,CAAA;AAC5D,O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ED;;OAEG;IACI,WAAW;QACjB,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,YAAY,EAAE,YAAY,EAAE,GAAG,IAAI,CAAA;QACrE,MAAM,IAAI,GAAqB;YAC9B;gBACC,CAAC,YAAY,EAAE,WAAW,CAAC;gBAC3B,CAAC,YAAY,EAAE,WAAW,CAAC;gBAC3B,CAAC,YAAY,EAAE,WAAW,CAAC;gBAC3B,CAAC,YAAY,EAAE,WAAW,CAAC;gBAC3B,CAAC,YAAY,EAAE,WAAW,CAAC;aAC3B;SACD,CAAA;QAED,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,WAAW,EAAE,IAAI,EAAE,CAAA;IAC9C,CAAC;IAED;;;;OAIG;IACI,QAAQ;QACd,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,YAAY,EAAE,YAAY,EAAE,GAAG,IAAI,CAAA;QAErE,OAAO,QAAQ,IAAI,CAAC,UAAU,aAAa,YAAY,IAAI,WAAW,KAAK,YAAY,IAAI,WAAW,KAAK,YAAY,IAAI,WAAW,KAAK,YAAY,IAAI,WAAW,KAAK,YAAY,IAAI,WAAW,IAAI,CAAA;IAC3M,CAAC;CAGD"}
|
|
@@ -26,17 +26,18 @@ export declare function toGeohash(lat: number, lon: number, precision?: number):
|
|
|
26
26
|
/** Maidenhead grid locator (default 6-char: field uppercase, square digits, subsquare lowercase). */
|
|
27
27
|
export declare function toMaidenhead(lat: number, lon: number, pairs?: number): string;
|
|
28
28
|
/**
|
|
29
|
-
* Sunrise / solar-noon / sunset for a coordinate on a date, as UTC epoch seconds, via the standard
|
|
30
|
-
*
|
|
31
|
-
*
|
|
29
|
+
* Sunrise / solar-noon / sunset for a coordinate on a date, as UTC epoch seconds, via the standard sunrise equation.
|
|
30
|
+
* `rise` and `set` are absent during polar day or polar night (the sun never crosses the horizon); `noon` (solar
|
|
31
|
+
* transit) is always present.
|
|
32
32
|
*/
|
|
33
33
|
export declare function sunTimes(lat: number, lon: number, date?: Date): {
|
|
34
34
|
rise?: number;
|
|
35
35
|
set?: number;
|
|
36
36
|
noon: number;
|
|
37
37
|
};
|
|
38
|
-
/**
|
|
39
|
-
(±80°/84°).
|
|
38
|
+
/**
|
|
39
|
+
* Military Grid Reference System for a coordinate (`"18SUJ2340806479"`); `""` outside MGRS bands (±80°/84°).
|
|
40
|
+
*/
|
|
40
41
|
export declare function toMGRS(lat: number, lon: number): string;
|
|
41
42
|
/** Fill the coordinate-format slice of an {@link AnnotationSet} from a `{lat, lon}`. */
|
|
42
43
|
export declare const coordinateFormatAnnotator: Annotator;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coordinate-formats.d.ts","sourceRoot":"","sources":["../coordinate-formats.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,wBAAwB,CAAA;AAmBtE,gDAAgD;AAChD,wBAAgB,KAAK,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAE5E;AAID,2DAA2D;AAC3D,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,
|
|
1
|
+
{"version":3,"file":"coordinate-formats.d.ts","sourceRoot":"","sources":["../coordinate-formats.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAiB,SAAS,EAAE,MAAM,wBAAwB,CAAA;AAmBtE,gDAAgD;AAChD,wBAAgB,KAAK,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAE5E;AAID,2DAA2D;AAC3D,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,CAAA;CAAE,CAO7E;AAID,iGAAiG;AACjG,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAQ7D;AAID,mFAAmF;AACnF,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,SAAS,SAAI,GAAG,MAAM,CA0CzE;AAID,qGAAqG;AACrG,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,SAAI,GAAG,MAAM,CAaxE;AAKD;;;;GAIG;AACH,wBAAgB,QAAQ,CACvB,GAAG,EAAE,MAAM,EACX,GAAG,EAAE,MAAM,EACX,IAAI,GAAE,IAAiB,GACrB;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAoB/C;AA4CD;;GAEG;AACH,wBAAgB,MAAM,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAavD;AAED,wFAAwF;AACxF,eAAO,MAAM,yBAAyB,EAAE,SAQtC,CAAA"}
|
|
@@ -11,8 +11,7 @@
|
|
|
11
11
|
const toRad = (d) => (d * Math.PI) / 180;
|
|
12
12
|
const toDeg = (r) => (r * 180) / Math.PI;
|
|
13
13
|
/**
|
|
14
|
-
* Render a single signed degree as `D° M′ S″ H` with the given hemisphere letters `[positive,
|
|
15
|
-
* negative]`.
|
|
14
|
+
* Render a single signed degree as `D° M′ S″ H` with the given hemisphere letters `[positive, negative]`.
|
|
16
15
|
*/
|
|
17
16
|
function dmsComponent(value, hemispheres, secondsDp = 2) {
|
|
18
17
|
const hemisphere = value >= 0 ? hemispheres[0] : hemispheres[1];
|
|
@@ -107,9 +106,9 @@ export function toMaidenhead(lat, lon, pairs = 3) {
|
|
|
107
106
|
const J2000 = 2451545.0;
|
|
108
107
|
const unixEpochJulian = 2440587.5;
|
|
109
108
|
/**
|
|
110
|
-
* Sunrise / solar-noon / sunset for a coordinate on a date, as UTC epoch seconds, via the standard
|
|
111
|
-
*
|
|
112
|
-
*
|
|
109
|
+
* Sunrise / solar-noon / sunset for a coordinate on a date, as UTC epoch seconds, via the standard sunrise equation.
|
|
110
|
+
* `rise` and `set` are absent during polar day or polar night (the sun never crosses the horizon); `noon` (solar
|
|
111
|
+
* transit) is always present.
|
|
113
112
|
*/
|
|
114
113
|
export function sunTimes(lat, lon, date = new Date()) {
|
|
115
114
|
const julian = date.getTime() / 86400000 + unixEpochJulian;
|
|
@@ -165,8 +164,9 @@ function latLonToUtm(lat, lon) {
|
|
|
165
164
|
const MGRS_LAT_BANDS = "CDEFGHJKLMNPQRSTUVWX";
|
|
166
165
|
const MGRS_COL_SETS = ["ABCDEFGH", "JKLMNPQR", "STUVWXYZ"];
|
|
167
166
|
const MGRS_ROW_LETTERS = "ABCDEFGHJKLMNPQRSTUV";
|
|
168
|
-
/**
|
|
169
|
-
(±80°/84°).
|
|
167
|
+
/**
|
|
168
|
+
* Military Grid Reference System for a coordinate (`"18SUJ2340806479"`); `""` outside MGRS bands (±80°/84°).
|
|
169
|
+
*/
|
|
170
170
|
export function toMGRS(lat, lon) {
|
|
171
171
|
if (lat < -80 || lat > 84)
|
|
172
172
|
return "";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coordinate-formats.js","sourceRoot":"","sources":["../coordinate-formats.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAIH,MAAM,KAAK,GAAG,CAAC,CAAS,EAAU,EAAE,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,GAAG,CAAA;AACxD,MAAM,KAAK,GAAG,CAAC,CAAS,EAAU,EAAE,CAAC,CAAC,CAAC,GAAG,G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