@kalisio/common-geospatial 0.0.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/LICENSE.md +21 -0
- package/README.md +17 -0
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.mjs +828 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +57 -0
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,828 @@
|
|
|
1
|
+
import { assert as l, is as i, has as M, conform as T, optional as C } from "@kalisio/common-core";
|
|
2
|
+
const d = {
|
|
3
|
+
LATITUDE: "LAT",
|
|
4
|
+
LONGITUDE: "LON",
|
|
5
|
+
ALTITUDE: "ALT"
|
|
6
|
+
};
|
|
7
|
+
function Z(e) {
|
|
8
|
+
return l.that(e, i.string, "axis must be a string"), Object.values(d).includes(e);
|
|
9
|
+
}
|
|
10
|
+
function R(e) {
|
|
11
|
+
return l.that(e, i.string, "axis must be a string"), e === d.LATITUDE;
|
|
12
|
+
}
|
|
13
|
+
function W(e) {
|
|
14
|
+
return l.that(e, i.string, "axis must be a string"), e === d.LONGITUDE;
|
|
15
|
+
}
|
|
16
|
+
function We(e) {
|
|
17
|
+
return l.that(e, i.string, "axis must be a string"), e === d.ALTITUDE;
|
|
18
|
+
}
|
|
19
|
+
const J = { NORTH: { label: "Nord", symbol: "N" }, SOUTH: { label: "Sud", symbol: "S" }, EAST: { label: "Est", symbol: "E" }, WEST: { label: "Ouest", symbol: "O" } }, ee = {
|
|
20
|
+
DIRECTIONS: J
|
|
21
|
+
}, te = { NORTH: { label: "North", symbol: "N" }, SOUTH: { label: "South", symbol: "S" }, EAST: { label: "East", symbol: "E" }, WEST: { label: "West", symbol: "W" } }, ne = {
|
|
22
|
+
DIRECTIONS: te
|
|
23
|
+
}, re = {
|
|
24
|
+
DIRECTIONS: {
|
|
25
|
+
NORTH: { label: i.string, symbol: i.string },
|
|
26
|
+
SOUTH: { label: i.string, symbol: i.string },
|
|
27
|
+
EAST: { label: i.string, symbol: i.string },
|
|
28
|
+
WEST: { label: i.string, symbol: i.string }
|
|
29
|
+
}
|
|
30
|
+
}, O = {
|
|
31
|
+
en: ne,
|
|
32
|
+
fr: ee
|
|
33
|
+
};
|
|
34
|
+
let w = "en";
|
|
35
|
+
function Be() {
|
|
36
|
+
return Object.keys(O);
|
|
37
|
+
}
|
|
38
|
+
function je(e, t) {
|
|
39
|
+
l.all([
|
|
40
|
+
{ value: e, validator: i.string, message: "code must be a string" },
|
|
41
|
+
{ value: e, validator: (n) => !M.key(O, n), message: "locale already registered" },
|
|
42
|
+
{ value: t, validator: i.plainObject, message: "content must be an object" },
|
|
43
|
+
{ value: t, validator: (n) => T.schema(n, re), message: "content does not conform to schema" }
|
|
44
|
+
]), O[e] = t;
|
|
45
|
+
}
|
|
46
|
+
function Ke(e) {
|
|
47
|
+
l.all([
|
|
48
|
+
{ value: e, validator: i.string, message: "code must be a string" },
|
|
49
|
+
{ value: e, validator: (t) => M.key(O, t), message: "code is unknown" }
|
|
50
|
+
]), w = e;
|
|
51
|
+
}
|
|
52
|
+
function ie() {
|
|
53
|
+
return {
|
|
54
|
+
code: w,
|
|
55
|
+
content: O[w]
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
function y() {
|
|
59
|
+
return ie().content.DIRECTIONS;
|
|
60
|
+
}
|
|
61
|
+
function S(e, t) {
|
|
62
|
+
const n = y(), r = n[e].label.toUpperCase(), s = n[e].symbol.toUpperCase();
|
|
63
|
+
return t.toUpperCase() === r || t.toUpperCase() === s;
|
|
64
|
+
}
|
|
65
|
+
function Ye(e = null) {
|
|
66
|
+
const t = y();
|
|
67
|
+
return i.defined(e) ? (l.that(e, Z, "axis must be a valid axis"), R(e) ? [t.SOUTH, t.NORTH] : W(e) ? [t.EAST, t.WEST] : []) : [t.SOUTH, t.NORTH, t.EAST, t.WEST];
|
|
68
|
+
}
|
|
69
|
+
function qe() {
|
|
70
|
+
return y().NORTH;
|
|
71
|
+
}
|
|
72
|
+
function ze() {
|
|
73
|
+
return y().SOUTH;
|
|
74
|
+
}
|
|
75
|
+
function Qe() {
|
|
76
|
+
return y().EAST;
|
|
77
|
+
}
|
|
78
|
+
function Xe() {
|
|
79
|
+
return y().WEST;
|
|
80
|
+
}
|
|
81
|
+
function v(e) {
|
|
82
|
+
return l.that(e, i.string, "dir must be a string"), se(e) || B(e) || j(e) || $(e);
|
|
83
|
+
}
|
|
84
|
+
function se(e) {
|
|
85
|
+
return l.that(e, i.string, "dir must be a string"), S("NORTH", e);
|
|
86
|
+
}
|
|
87
|
+
function B(e) {
|
|
88
|
+
return l.that(e, i.string, "dir must be a string"), S("SOUTH", e);
|
|
89
|
+
}
|
|
90
|
+
function j(e) {
|
|
91
|
+
return l.that(e, i.string, "dir must be a string"), S("EAST", e);
|
|
92
|
+
}
|
|
93
|
+
function $(e) {
|
|
94
|
+
return l.that(e, i.string, "dir must be a string"), S("WEST", e);
|
|
95
|
+
}
|
|
96
|
+
function ae(e) {
|
|
97
|
+
return l.that(e, v, "dir must be a direction"), $(e) || j(e) ? d.LONGITUDE : d.LATITUDE;
|
|
98
|
+
}
|
|
99
|
+
const oe = {
|
|
100
|
+
degrees: i.number,
|
|
101
|
+
direction: C(v)
|
|
102
|
+
}, ue = /^(-?\d{1,3}(?:\.\d+)?)°?$/, le = /^(\d{1,3}(?:\.\d+)?)°?([NSEW])$/;
|
|
103
|
+
function L(e) {
|
|
104
|
+
let t = null, n = null;
|
|
105
|
+
if (i.plainObject(e) && T.schema(e, oe))
|
|
106
|
+
i.defined(e.direction) ? e.degrees >= 0 && (t = e.degrees, n = e.direction) : t = e.degrees;
|
|
107
|
+
else if (i.string(e)) {
|
|
108
|
+
const r = e.replace(/\s+/g, ""), s = r.match(ue) ?? r.match(le);
|
|
109
|
+
s && (t = parseFloat(s[1]), n = s[2] ?? null);
|
|
110
|
+
}
|
|
111
|
+
return {
|
|
112
|
+
get degrees() {
|
|
113
|
+
return t;
|
|
114
|
+
},
|
|
115
|
+
get direction() {
|
|
116
|
+
return n;
|
|
117
|
+
},
|
|
118
|
+
get format() {
|
|
119
|
+
return "DD";
|
|
120
|
+
},
|
|
121
|
+
isValid() {
|
|
122
|
+
return i.number(t);
|
|
123
|
+
},
|
|
124
|
+
toString(r) {
|
|
125
|
+
if (l.that(r, i.positiveInteger, "decimalPlaces must be a positive integer"), !this.isValid()) return "";
|
|
126
|
+
let s = `${t.toFixed(r)}°`;
|
|
127
|
+
return n && (s += ` ${n}`), s;
|
|
128
|
+
},
|
|
129
|
+
toDecimal() {
|
|
130
|
+
return this.isValid() ? L({ degrees: t, direction: n }) : null;
|
|
131
|
+
}
|
|
132
|
+
};
|
|
133
|
+
}
|
|
134
|
+
const ce = {
|
|
135
|
+
degrees: i.integer,
|
|
136
|
+
minutes: (e) => i.inRangeExclusiveMax(e, 0, 60),
|
|
137
|
+
direction: C(v)
|
|
138
|
+
}, ge = /^(-?\d{1,3})°(\d{1,2}(?:\.\d+)?)'?$/, fe = /^(\d{1,3})°(\d{1,2}(?:\.\d+)?)'?([NSEW])$/;
|
|
139
|
+
function K(e) {
|
|
140
|
+
let t = null, n = null, r = null;
|
|
141
|
+
if (i.plainObject(e) && T.schema(e, ce))
|
|
142
|
+
i.defined(e.direction) ? e.degrees >= 0 && (t = e.degrees, n = e.minutes, r = e.direction) : (t = e.degrees, n = e.minutes);
|
|
143
|
+
else if (i.string(e)) {
|
|
144
|
+
const s = e.replace(/\s+/g, ""), a = s.match(ge) ?? s.match(fe);
|
|
145
|
+
a && (t = parseFloat(a[1]), n = parseFloat(a[2]), r = a[3] ?? null);
|
|
146
|
+
}
|
|
147
|
+
return {
|
|
148
|
+
get degrees() {
|
|
149
|
+
return t;
|
|
150
|
+
},
|
|
151
|
+
get minutes() {
|
|
152
|
+
return n;
|
|
153
|
+
},
|
|
154
|
+
get direction() {
|
|
155
|
+
return r;
|
|
156
|
+
},
|
|
157
|
+
get format() {
|
|
158
|
+
return "DDM";
|
|
159
|
+
},
|
|
160
|
+
isValid() {
|
|
161
|
+
return i.integer(t) && i.inRangeExclusiveMax(n, 0, 60);
|
|
162
|
+
},
|
|
163
|
+
toString(s) {
|
|
164
|
+
if (l.that(s, i.positiveInteger, "decimalPlaces must be a positive integer"), !this.isValid()) return "";
|
|
165
|
+
let a = `${t}° ${n.toFixed(s)}'`;
|
|
166
|
+
return r && (a += ` ${r}`), a;
|
|
167
|
+
},
|
|
168
|
+
toDecimal() {
|
|
169
|
+
return this.isValid() ? L({ degrees: t + n / 60, direction: r }) : null;
|
|
170
|
+
}
|
|
171
|
+
};
|
|
172
|
+
}
|
|
173
|
+
const me = {
|
|
174
|
+
degrees: i.nonNegativeInteger,
|
|
175
|
+
minutes: (e) => i.inRangeExclusiveMax(e, 0, 60),
|
|
176
|
+
direction: v
|
|
177
|
+
}, de = /^(\d{2})(\d{3})([NS])$/, Ee = /^(\d{3})(\d{3})([EW])$/;
|
|
178
|
+
function Y(e) {
|
|
179
|
+
let t = null, n = null, r = null;
|
|
180
|
+
if (i.plainObject(e) && T.schema(e, me))
|
|
181
|
+
t = e.degrees, n = e.minutes, r = e.direction;
|
|
182
|
+
else if (i.string(e)) {
|
|
183
|
+
const s = e.trim(), a = s.match(de) ?? s.match(Ee);
|
|
184
|
+
a && (t = parseFloat(a[1]), n = parseFloat(a[2]) / 10, r = a[3]);
|
|
185
|
+
}
|
|
186
|
+
return {
|
|
187
|
+
get degrees() {
|
|
188
|
+
return t;
|
|
189
|
+
},
|
|
190
|
+
get minutes() {
|
|
191
|
+
return n;
|
|
192
|
+
},
|
|
193
|
+
get direction() {
|
|
194
|
+
return r;
|
|
195
|
+
},
|
|
196
|
+
get format() {
|
|
197
|
+
return "DDM_AERO";
|
|
198
|
+
},
|
|
199
|
+
isValid() {
|
|
200
|
+
return i.nonNegativeInteger(t) && i.inRangeExclusiveMax(n, 0, 60) && v(r);
|
|
201
|
+
},
|
|
202
|
+
toString() {
|
|
203
|
+
if (!this.isValid()) return "";
|
|
204
|
+
const s = r === "E" || r === "W", a = String(t).padStart(s ? 3 : 2, "0"), o = Math.floor(n * 10).toString().padStart(3, "0");
|
|
205
|
+
return `${a}${o}${r}`;
|
|
206
|
+
},
|
|
207
|
+
toDecimal() {
|
|
208
|
+
return this.isValid() ? L({ degrees: t + n / 60, direction: r }) : null;
|
|
209
|
+
}
|
|
210
|
+
};
|
|
211
|
+
}
|
|
212
|
+
const pe = {
|
|
213
|
+
degrees: i.integer,
|
|
214
|
+
minutes: (e) => i.integer(e) && i.inRange(e, 0, 59),
|
|
215
|
+
seconds: (e) => i.inRangeExclusiveMax(e, 0, 60),
|
|
216
|
+
direction: C(v)
|
|
217
|
+
}, ve = /^(-?\d{1,3})°(\d{1,2})'(\d{1,2}(?:\.\d+)?)"?$/, he = /^(\d{1,3})°(\d{1,2})'(\d{1,2}(?:\.\d+)?)"?([NSEW])$/;
|
|
218
|
+
function q(e) {
|
|
219
|
+
let t = null, n = null, r = null, s = null;
|
|
220
|
+
if (i.plainObject(e) && T.schema(e, pe))
|
|
221
|
+
i.defined(e.direction) ? e.degrees >= 0 && (t = e.degrees, n = e.minutes, r = e.seconds, s = e.direction) : (t = e.degrees, n = e.minutes, r = e.seconds);
|
|
222
|
+
else if (i.string(e)) {
|
|
223
|
+
const a = e.replace(/\s+/g, ""), o = a.match(ve) ?? a.match(he);
|
|
224
|
+
o && (t = parseFloat(o[1]), n = parseFloat(o[2]), r = parseFloat(o[3]), s = o[4] ?? null);
|
|
225
|
+
}
|
|
226
|
+
return {
|
|
227
|
+
get degrees() {
|
|
228
|
+
return t;
|
|
229
|
+
},
|
|
230
|
+
get minutes() {
|
|
231
|
+
return n;
|
|
232
|
+
},
|
|
233
|
+
get seconds() {
|
|
234
|
+
return r;
|
|
235
|
+
},
|
|
236
|
+
get direction() {
|
|
237
|
+
return s;
|
|
238
|
+
},
|
|
239
|
+
get format() {
|
|
240
|
+
return "DMS";
|
|
241
|
+
},
|
|
242
|
+
isValid() {
|
|
243
|
+
return i.integer(t) && i.integer(n) && i.inRange(n, 0, 59) && i.inRangeExclusiveMax(r, 0, 60);
|
|
244
|
+
},
|
|
245
|
+
toString(a) {
|
|
246
|
+
if (l.that(a, i.positiveInteger, "decimalPlaces must be a positive integer"), !this.isValid()) return "";
|
|
247
|
+
let o = `${t}° ${n}' ${r.toFixed(a)}"`;
|
|
248
|
+
return s && (o += ` ${s}`), o;
|
|
249
|
+
},
|
|
250
|
+
toDecimal() {
|
|
251
|
+
return this.isValid() ? L({ degrees: t + n / 60 + r / 3600, direction: s }) : null;
|
|
252
|
+
}
|
|
253
|
+
};
|
|
254
|
+
}
|
|
255
|
+
function F(e) {
|
|
256
|
+
const t = Math.floor(e.degrees), n = (e.degrees - t) * 60;
|
|
257
|
+
return { degrees: t, minutes: n, direction: e.direction };
|
|
258
|
+
}
|
|
259
|
+
function ye(e) {
|
|
260
|
+
const t = Math.floor(e.degrees), n = (e.degrees - t) * 60, r = Math.floor(n), s = (n - r) * 60;
|
|
261
|
+
return { degrees: t, minutes: r, seconds: s, direction: e.direction };
|
|
262
|
+
}
|
|
263
|
+
const k = {
|
|
264
|
+
DD: (e) => (l.that(e, (t) => t.isValid(), "dd must be a valid coordinate"), e),
|
|
265
|
+
DDM: (e) => {
|
|
266
|
+
l.that(e, (s) => s.isValid(), "dd must be a valid coordinate");
|
|
267
|
+
const { degrees: t, minutes: n, direction: r } = F(e);
|
|
268
|
+
return K(r ? { degrees: t, minutes: n, direction: r } : { degrees: t, minutes: n });
|
|
269
|
+
},
|
|
270
|
+
DMS: (e) => {
|
|
271
|
+
l.that(e, (a) => a.isValid(), "dd must be a valid coordinate");
|
|
272
|
+
const { degrees: t, minutes: n, seconds: r, direction: s } = ye(e);
|
|
273
|
+
return q(s ? { degrees: t, minutes: n, seconds: r, direction: s } : { degrees: t, minutes: n, seconds: r });
|
|
274
|
+
},
|
|
275
|
+
DDM_AERO: (e) => {
|
|
276
|
+
l.that(e, (s) => s.isValid(), "dd must be a valid coordinate");
|
|
277
|
+
const { degrees: t, minutes: n, direction: r } = F(e);
|
|
278
|
+
return Y({ degrees: t, minutes: n, direction: r });
|
|
279
|
+
}
|
|
280
|
+
}, N = {
|
|
281
|
+
DD: "DD",
|
|
282
|
+
DDM: "DDM",
|
|
283
|
+
DDM_AERO: "DDM_AERO",
|
|
284
|
+
DMS: "DMS"
|
|
285
|
+
}, be = {
|
|
286
|
+
DD: L,
|
|
287
|
+
DDM: K,
|
|
288
|
+
DDM_AERO: Y,
|
|
289
|
+
DMS: q
|
|
290
|
+
}, _ = Array.from({ length: 9 }, (e, t) => 10 ** t);
|
|
291
|
+
function P(e, t) {
|
|
292
|
+
if (l.that(e, i.number, "coord must be a number"), i.defined(t))
|
|
293
|
+
return l.that(t, v, "dir must be a direction"), ae(t);
|
|
294
|
+
if (Math.abs(e) > 90) return d.LONGITUDE;
|
|
295
|
+
}
|
|
296
|
+
function H(e) {
|
|
297
|
+
l.that(e, i.number, "coord must be a number");
|
|
298
|
+
const t = e.toExponential(), [n, r] = t.split("e").map(Number), s = (n.toString().split(".")[1] || "").length;
|
|
299
|
+
return Math.max(0, s - r);
|
|
300
|
+
}
|
|
301
|
+
function Ze(e, t = 7) {
|
|
302
|
+
l.all([
|
|
303
|
+
{ value: e, validator: i.number, message: "coord must be a number" },
|
|
304
|
+
{ value: t, validator: (r) => i.inRange(r, 0, 8), message: "precision must be in range [0, 8]" }
|
|
305
|
+
]);
|
|
306
|
+
const n = _[t];
|
|
307
|
+
return Math.round(e * n) / n;
|
|
308
|
+
}
|
|
309
|
+
function Je(e, t) {
|
|
310
|
+
if (l.all([
|
|
311
|
+
{ value: e, validator: i.number, message: "coord must be a number" },
|
|
312
|
+
{ value: t, validator: (r) => W(r) || R(r), message: "axis must be either a longitude or latitude" }
|
|
313
|
+
]), R(t))
|
|
314
|
+
return Math.max(-90, Math.min(90, e));
|
|
315
|
+
let n = ((e + 180) % 360 + 360) % 360 - 180;
|
|
316
|
+
return n === -180 && (n = 180), Object.is(n, -0) && (n = 0), n;
|
|
317
|
+
}
|
|
318
|
+
function et(e, t) {
|
|
319
|
+
l.all([
|
|
320
|
+
{ value: e, validator: (r) => i.defined(r) && r.isValid(), message: "from must be a valid coordinate" },
|
|
321
|
+
{ value: t, validator: (r) => M.key(k, r), message: `unknown format: ${t}` }
|
|
322
|
+
]);
|
|
323
|
+
const n = e.format === N.DD ? e : e.toDecimal();
|
|
324
|
+
return n.isValid() ? t === N.DD ? n : k[t](n) : null;
|
|
325
|
+
}
|
|
326
|
+
function Oe(e) {
|
|
327
|
+
l.that(e, i.nonEmptyString, "pattern must be a non empty string");
|
|
328
|
+
for (const t of Object.keys(N)) {
|
|
329
|
+
const n = be[t](e);
|
|
330
|
+
if (n.isValid()) return n;
|
|
331
|
+
}
|
|
332
|
+
return null;
|
|
333
|
+
}
|
|
334
|
+
function tt(e) {
|
|
335
|
+
l.that(e, (f) => i.nonEmptyString(f), "pattern must be a non-empty string");
|
|
336
|
+
const t = e.split(/[,;|]/);
|
|
337
|
+
if (t.length !== 2) return null;
|
|
338
|
+
const [n, r] = t.map(Oe);
|
|
339
|
+
if (!n || !r) return null;
|
|
340
|
+
const s = n.toDecimal(), a = r.toDecimal(), o = P(s.degrees, s.direction), u = P(a.degrees, a.direction), c = (f) => {
|
|
341
|
+
const { degrees: m, direction: g } = f;
|
|
342
|
+
return g && ($(g) || B(g)) ? -m : m;
|
|
343
|
+
};
|
|
344
|
+
if (o === d.LONGITUDE && u === d.LATITUDE) return [c(s), c(a)];
|
|
345
|
+
if (u === d.LONGITUDE && o === d.LATITUDE) return [c(a), c(s)];
|
|
346
|
+
if (o === d.LONGITUDE && !u) return [c(s), a];
|
|
347
|
+
if (o === d.LATITUDE && !u) return [c(a), c(s)];
|
|
348
|
+
if (u === d.LONGITUDE && !o) return [c(a), c(s)];
|
|
349
|
+
if (u === d.LATITUDE && !o) return [c(s), c(a)];
|
|
350
|
+
if (!o && !u)
|
|
351
|
+
return [
|
|
352
|
+
[c(s), c(a)],
|
|
353
|
+
[c(a), c(s)]
|
|
354
|
+
];
|
|
355
|
+
}
|
|
356
|
+
function Te(e) {
|
|
357
|
+
return !i.arrayOfLength(e, 4) && !i.arrayOfLength(e, 6) ? !1 : e.every(i.number);
|
|
358
|
+
}
|
|
359
|
+
const D = {
|
|
360
|
+
NAME: "name",
|
|
361
|
+
LINK: "link"
|
|
362
|
+
};
|
|
363
|
+
function nt(e) {
|
|
364
|
+
return i.plainObject(e) ? e.type === D.NAME ? i.nonEmptyString(e.properties?.name) : e.type === D.LINK ? i.nonEmptyString(e.properties?.href) : !1 : !1;
|
|
365
|
+
}
|
|
366
|
+
const p = {
|
|
367
|
+
POINT: "Point",
|
|
368
|
+
MULTI_POINT: "MultiPoint",
|
|
369
|
+
LINESTRING: "LineString",
|
|
370
|
+
MULTI_LINESTRING: "MultiLineString",
|
|
371
|
+
POLYGON: "Polygon",
|
|
372
|
+
MULTI_POLYGON: "MultiPolygon",
|
|
373
|
+
GEOMETRY_COLLECTION: "GeometryCollection"
|
|
374
|
+
};
|
|
375
|
+
function Le(e) {
|
|
376
|
+
return !i.plainObject(e) || !i.oneOf(e.type, Object.values(p)) ? !1 : e.type === p.GEOMETRY_COLLECTION ? i.array(e.geometries) : i.array(e.coordinates);
|
|
377
|
+
}
|
|
378
|
+
const h = {
|
|
379
|
+
FEATURE: "Feature",
|
|
380
|
+
FEATURE_COLLECTION: "FeatureCollection"
|
|
381
|
+
};
|
|
382
|
+
function De(e) {
|
|
383
|
+
return i.plainObject(e) ? h.FEATURE === e.type : !1;
|
|
384
|
+
}
|
|
385
|
+
function Ie(e) {
|
|
386
|
+
return !i.plainObject(e) || e.type !== h.FEATURE_COLLECTION ? !1 : i.array(e.features);
|
|
387
|
+
}
|
|
388
|
+
function rt(e) {
|
|
389
|
+
return i.plainObject(e) ? Le(e) || De(e) ? !0 : Ie(e) : !1;
|
|
390
|
+
}
|
|
391
|
+
function Se(e) {
|
|
392
|
+
return i.arrayOfLengthBetween(e, 2, 3) ? e.every(i.number) : !1;
|
|
393
|
+
}
|
|
394
|
+
function it(e, t = 7) {
|
|
395
|
+
l.all([
|
|
396
|
+
{ value: e, validator: Te, message: "bbox must be bounding box" },
|
|
397
|
+
{ value: t, validator: (r) => i.inRange(r, 0, 8), message: "precision must be in range [0, 8]" }
|
|
398
|
+
]);
|
|
399
|
+
const n = _[t];
|
|
400
|
+
for (let r = 0; r < e.length; r++)
|
|
401
|
+
e[r] = Math.round(e[r] * n) / n;
|
|
402
|
+
return e;
|
|
403
|
+
}
|
|
404
|
+
function st(e, t = 7) {
|
|
405
|
+
l.all([
|
|
406
|
+
{ value: e, validator: Se, message: "position must be a position" },
|
|
407
|
+
{ value: t, validator: (r) => i.inRange(r, 0, 8), message: "precision must be in range [0, 8]" }
|
|
408
|
+
]);
|
|
409
|
+
const n = _[t];
|
|
410
|
+
for (let r = 0; r < e.length; r++)
|
|
411
|
+
e[r] = Math.round(e[r] * n) / n;
|
|
412
|
+
return e;
|
|
413
|
+
}
|
|
414
|
+
function I(e) {
|
|
415
|
+
if (!i.arrayOfLengthBetween(e, 2, 3))
|
|
416
|
+
return {
|
|
417
|
+
valid: !1,
|
|
418
|
+
errors: [{ message: "Invalid coordinates: must be an array of 2 or 3 coordinates" }],
|
|
419
|
+
warnings: []
|
|
420
|
+
};
|
|
421
|
+
if (!i.inRange(e[0], -180, 180))
|
|
422
|
+
return {
|
|
423
|
+
valid: !1,
|
|
424
|
+
errors: [{ message: "Invalid coordinates: longitude must be in the range -180 to 180" }],
|
|
425
|
+
warnings: []
|
|
426
|
+
};
|
|
427
|
+
if (!i.inRange(e[1], -90, 90))
|
|
428
|
+
return {
|
|
429
|
+
valid: !1,
|
|
430
|
+
errors: [{ message: "Invalid coordinates: latitude must be in the range -90 to 90" }],
|
|
431
|
+
warnings: []
|
|
432
|
+
};
|
|
433
|
+
if (e.length === 3 && !i.number(e[2]))
|
|
434
|
+
return {
|
|
435
|
+
valid: !1,
|
|
436
|
+
errors: [{ message: "Invalid coordinates: altitude must be a number" }],
|
|
437
|
+
warnings: []
|
|
438
|
+
};
|
|
439
|
+
const t = { valid: !0, errors: [], warnings: [] }, n = H(e[0]);
|
|
440
|
+
n > 6 && t.warnings.push({ message: `longitude precision is high (${n} decimals, max recommended: 6)` });
|
|
441
|
+
const r = H(e[1]);
|
|
442
|
+
return r > 6 && t.warnings.push({ message: `latitude precision is high (${r} decimals, max recommended: 6)` }), t;
|
|
443
|
+
}
|
|
444
|
+
function Re(e) {
|
|
445
|
+
if (!i.arrayOfLength(e, 4) && !i.arrayOfLength(e, 6))
|
|
446
|
+
return {
|
|
447
|
+
valid: !1,
|
|
448
|
+
errors: [{ message: "Invalid bbox: must be an array of 4 (2D) or 6 (3D) numbers" }],
|
|
449
|
+
warnings: []
|
|
450
|
+
};
|
|
451
|
+
const t = e.length === 4, n = t ? [e[0], e[1]] : [e[0], e[1], e[2]], r = t ? [e[2], e[3]] : [e[3], e[4], e[5]], s = I(n);
|
|
452
|
+
if (!s.valid)
|
|
453
|
+
return {
|
|
454
|
+
valid: !1,
|
|
455
|
+
errors: s.errors.map((g) => ({ ...g, message: `Invalid bbox south-west: ${g.message}` })),
|
|
456
|
+
warnings: []
|
|
457
|
+
};
|
|
458
|
+
const a = I(r);
|
|
459
|
+
if (!a.valid)
|
|
460
|
+
return {
|
|
461
|
+
valid: !1,
|
|
462
|
+
errors: a.errors.map((g) => ({ ...g, message: `Invalid bbox north-east: ${g.message}` })),
|
|
463
|
+
warnings: []
|
|
464
|
+
};
|
|
465
|
+
const [o, u] = n, [c, f] = r;
|
|
466
|
+
if (u > f)
|
|
467
|
+
return {
|
|
468
|
+
valid: !1,
|
|
469
|
+
errors: [{ message: `Invalid bbox: south (${u}) must be <= north (${f})` }],
|
|
470
|
+
warnings: []
|
|
471
|
+
};
|
|
472
|
+
const m = { valid: !0, errors: [], warnings: [] };
|
|
473
|
+
return o > c && m.warnings.push({ message: `bbox crosses the antimeridian (west: ${o} > east: ${c})` }), m.warnings.push(...s.warnings.map((g) => ({ ...g, message: `south-west: ${g.message}` }))), m.warnings.push(...a.warnings.map((g) => ({ ...g, message: `north-east: ${g.message}` }))), m;
|
|
474
|
+
}
|
|
475
|
+
function we(e) {
|
|
476
|
+
if (!i.plainObject(e))
|
|
477
|
+
return {
|
|
478
|
+
valid: !1,
|
|
479
|
+
errors: [{ message: "Invalid crs: must be an object" }],
|
|
480
|
+
warnings: []
|
|
481
|
+
};
|
|
482
|
+
switch (e.type) {
|
|
483
|
+
case D.NAME:
|
|
484
|
+
return i.nonEmptyString(e.properties?.name) ? { valid: !0, errors: [], warnings: [] } : {
|
|
485
|
+
valid: !1,
|
|
486
|
+
errors: [{ message: "Invalid crs: linked crs must have a non-empty properties.name string" }],
|
|
487
|
+
warnings: []
|
|
488
|
+
};
|
|
489
|
+
case D.LINK:
|
|
490
|
+
return i.nonEmptyString(e.properties?.href) ? { valid: !0, errors: [], warnings: [] } : {
|
|
491
|
+
valid: !1,
|
|
492
|
+
errors: [{ message: "Invalid crs: linked crs must have a non-empty properties.href string" }],
|
|
493
|
+
warnings: []
|
|
494
|
+
};
|
|
495
|
+
default:
|
|
496
|
+
return {
|
|
497
|
+
valid: !1,
|
|
498
|
+
errors: [{ message: `Invalid crs: unknown type: ${e.type}` }],
|
|
499
|
+
warnings: []
|
|
500
|
+
};
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
function Ne(e, t, n = {}) {
|
|
504
|
+
const r = { type: "Feature" };
|
|
505
|
+
return (n.id === 0 || n.id) && (r.id = n.id), n.bbox && (r.bbox = n.bbox), r.properties = {}, r.geometry = e, r;
|
|
506
|
+
}
|
|
507
|
+
function Ae(e, t, n = {}) {
|
|
508
|
+
if (!e)
|
|
509
|
+
throw new Error("coordinates is required");
|
|
510
|
+
if (!Array.isArray(e))
|
|
511
|
+
throw new Error("coordinates must be an Array");
|
|
512
|
+
if (e.length < 2)
|
|
513
|
+
throw new Error("coordinates must be at least 2 numbers long");
|
|
514
|
+
if (!V(e[0]) || !V(e[1]))
|
|
515
|
+
throw new Error("coordinates must contain numbers");
|
|
516
|
+
return Ne({
|
|
517
|
+
type: "Point",
|
|
518
|
+
coordinates: e
|
|
519
|
+
}, t, n);
|
|
520
|
+
}
|
|
521
|
+
function V(e) {
|
|
522
|
+
return !isNaN(e) && e !== null && !Array.isArray(e);
|
|
523
|
+
}
|
|
524
|
+
function Me(e) {
|
|
525
|
+
if (Array.isArray(e))
|
|
526
|
+
return e;
|
|
527
|
+
if (e.type === "Feature") {
|
|
528
|
+
if (e.geometry !== null)
|
|
529
|
+
return e.geometry.coordinates;
|
|
530
|
+
} else if (e.coordinates)
|
|
531
|
+
return e.coordinates;
|
|
532
|
+
throw new Error(
|
|
533
|
+
"coords must be GeoJSON Feature, Geometry Object or an Array"
|
|
534
|
+
);
|
|
535
|
+
}
|
|
536
|
+
function Ce(e) {
|
|
537
|
+
const t = Me(e);
|
|
538
|
+
let n = 0, r = 1, s, a;
|
|
539
|
+
for (; r < t.length; )
|
|
540
|
+
s = a || t[0], a = t[r], n += (a[0] - s[0]) * (a[1] + s[1]), r++;
|
|
541
|
+
return n > 0;
|
|
542
|
+
}
|
|
543
|
+
var $e = Ce;
|
|
544
|
+
function _e(e) {
|
|
545
|
+
let t, n;
|
|
546
|
+
const r = {
|
|
547
|
+
type: "FeatureCollection",
|
|
548
|
+
features: []
|
|
549
|
+
};
|
|
550
|
+
if (e.type === "Feature" ? n = e.geometry : n = e, n.type === "LineString")
|
|
551
|
+
t = [n.coordinates];
|
|
552
|
+
else if (n.type === "MultiLineString")
|
|
553
|
+
t = n.coordinates;
|
|
554
|
+
else if (n.type === "MultiPolygon")
|
|
555
|
+
t = [].concat(...n.coordinates);
|
|
556
|
+
else if (n.type === "Polygon")
|
|
557
|
+
t = n.coordinates;
|
|
558
|
+
else
|
|
559
|
+
throw new Error(
|
|
560
|
+
"Input must be a LineString, MultiLineString, Polygon, or MultiPolygon Feature or Geometry"
|
|
561
|
+
);
|
|
562
|
+
return t.forEach((s) => {
|
|
563
|
+
t.forEach((a) => {
|
|
564
|
+
for (let o = 0; o < s.length - 1; o++)
|
|
565
|
+
for (let u = o; u < a.length - 1; u++) {
|
|
566
|
+
if (s === a && (Math.abs(o - u) === 1 || // segments are first and last segment of lineString
|
|
567
|
+
o === 0 && u === s.length - 2 && // lineString is closed
|
|
568
|
+
s[o][0] === s[s.length - 1][0] && s[o][1] === s[s.length - 1][1]))
|
|
569
|
+
continue;
|
|
570
|
+
const c = Ue(
|
|
571
|
+
s[o][0],
|
|
572
|
+
s[o][1],
|
|
573
|
+
s[o + 1][0],
|
|
574
|
+
s[o + 1][1],
|
|
575
|
+
a[u][0],
|
|
576
|
+
a[u][1],
|
|
577
|
+
a[u + 1][0],
|
|
578
|
+
a[u + 1][1]
|
|
579
|
+
);
|
|
580
|
+
c && r.features.push(Ae([c[0], c[1]]));
|
|
581
|
+
}
|
|
582
|
+
});
|
|
583
|
+
}), r;
|
|
584
|
+
}
|
|
585
|
+
function Ue(e, t, n, r, s, a, o, u) {
|
|
586
|
+
let c, f, m, g, x;
|
|
587
|
+
const E = {
|
|
588
|
+
x: null,
|
|
589
|
+
y: null,
|
|
590
|
+
onLine1: !1,
|
|
591
|
+
onLine2: !1
|
|
592
|
+
};
|
|
593
|
+
return c = (u - a) * (n - e) - (o - s) * (r - t), c === 0 ? E.x !== null && E.y !== null ? E : !1 : (f = t - a, m = e - s, g = (o - s) * f - (u - a) * m, x = (n - e) * f - (r - t) * m, f = g / c, m = x / c, E.x = e + f * (n - e), E.y = t + f * (r - t), f >= 0 && f <= 1 && (E.onLine1 = !0), m >= 0 && m <= 1 && (E.onLine2 = !0), E.onLine1 && E.onLine2 ? [E.x, E.y] : !1);
|
|
594
|
+
}
|
|
595
|
+
var Ge = _e;
|
|
596
|
+
function xe(e, t) {
|
|
597
|
+
if (!i.defined(e.crs)) return t;
|
|
598
|
+
const n = we(e.crs);
|
|
599
|
+
return n.valid || (t.valid = !1, t.errors.push(...n.errors.map((r) => ({ ...r, path: "/crs" })))), t.warnings.push(...n.warnings.map((r) => ({ ...r, path: "/crs" }))), t;
|
|
600
|
+
}
|
|
601
|
+
function A(e, t, n = "") {
|
|
602
|
+
if (!i.defined(e.bbox)) return t;
|
|
603
|
+
const r = Re(e.bbox);
|
|
604
|
+
return r.valid || (t.valid = !1, t.errors.push(...r.errors.map((s) => ({ ...s, path: `${n}/bbox` })))), t.warnings.push(...r.warnings.map((s) => ({ ...s, path: `${n}/bbox` }))), t;
|
|
605
|
+
}
|
|
606
|
+
function b(e, t, n = "") {
|
|
607
|
+
const r = {
|
|
608
|
+
valid: !0,
|
|
609
|
+
errors: [],
|
|
610
|
+
warnings: []
|
|
611
|
+
};
|
|
612
|
+
for (let s = 0; s < e.length; s++) {
|
|
613
|
+
const a = `${n}/${s}`, o = t(e[s], a, s);
|
|
614
|
+
if (!o.valid) {
|
|
615
|
+
r.valid = !1, r.errors = r.errors.concat(o.errors.map((u) => ({ ...u, path: u.path || a, index: s })));
|
|
616
|
+
continue;
|
|
617
|
+
}
|
|
618
|
+
i.empty(o.warnings) || (r.warnings = r.warnings.concat(o.warnings.map((u) => ({ ...u, path: u.path || a, index: s }))));
|
|
619
|
+
}
|
|
620
|
+
return r;
|
|
621
|
+
}
|
|
622
|
+
function U(e, t = 0, n = "") {
|
|
623
|
+
return i.arrayOfLengthAtLeast(e, t) ? b(e, I, n) : {
|
|
624
|
+
valid: !1,
|
|
625
|
+
errors: [{ message: `Invalid coordinates: must have at least ${t} positions`, path: n }],
|
|
626
|
+
warnings: []
|
|
627
|
+
};
|
|
628
|
+
}
|
|
629
|
+
function z(e, t = "") {
|
|
630
|
+
const n = U(e, 2, t);
|
|
631
|
+
if (!n.valid) return n;
|
|
632
|
+
for (let r = 0; r < e.length - 1; r++) {
|
|
633
|
+
const s = e[r][0], a = e[r + 1][0];
|
|
634
|
+
Math.abs(a - s) > 180 && n.warnings.push({
|
|
635
|
+
message: `LineString crosses the antimeridian between positions ${r} and ${r + 1}, consider using MultiLineString`,
|
|
636
|
+
path: `${t}/${r}`
|
|
637
|
+
});
|
|
638
|
+
}
|
|
639
|
+
return n;
|
|
640
|
+
}
|
|
641
|
+
function Fe(e, t = "") {
|
|
642
|
+
return i.nonEmptyArray(e) ? b(e, z, t) : {
|
|
643
|
+
valid: !1,
|
|
644
|
+
errors: [{ message: "Invalid MultiLineString: coordinates must be a non empty array", path: t }],
|
|
645
|
+
warnings: []
|
|
646
|
+
};
|
|
647
|
+
}
|
|
648
|
+
function ke(e, t, n = "") {
|
|
649
|
+
const r = U(e, 4, n);
|
|
650
|
+
if (!r.valid) return r;
|
|
651
|
+
const s = e[0], a = e[e.length - 1];
|
|
652
|
+
if (s[0] !== a[0] || s[1] !== a[1])
|
|
653
|
+
return r.valid = !1, r.errors.push({ message: "Invalid LinearRing: first and last position must be identical", path: n }), r;
|
|
654
|
+
const u = $e(e) ? "clockwise" : "counter-clockwise";
|
|
655
|
+
u !== t && r.warnings.push({ message: `Ring must be ${t} but is ${u}`, path: n });
|
|
656
|
+
const c = Ge({ type: "Polygon", coordinates: [e] });
|
|
657
|
+
return c.features.length > 0 && (r.valid = !1, r.errors.push({ message: `Invalid LinearRing: ${c.features.length} self-intersection(s) detected`, path: n })), r;
|
|
658
|
+
}
|
|
659
|
+
function Q(e, t = "") {
|
|
660
|
+
return i.nonEmptyArray(e) ? b(e, (n, r, s) => ke(n, s === 0 ? "counter-clockwise" : "clockwise", r), t) : {
|
|
661
|
+
valid: !1,
|
|
662
|
+
errors: [{ message: "Invalid Polygon: coordinates must be a non empty array", path: t }],
|
|
663
|
+
warnings: []
|
|
664
|
+
};
|
|
665
|
+
}
|
|
666
|
+
function Pe(e, t = "") {
|
|
667
|
+
return i.nonEmptyArray(e) ? b(e, (n, r) => Q(n, r), t) : {
|
|
668
|
+
valid: !1,
|
|
669
|
+
errors: [{ message: "Invalid MultiPolygon: coordinates must be a non empty array", path: t }],
|
|
670
|
+
warnings: []
|
|
671
|
+
};
|
|
672
|
+
}
|
|
673
|
+
function He(e, t = "") {
|
|
674
|
+
return i.nonEmptyArray(e) ? b(e, (n, r) => G(n, r), t) : {
|
|
675
|
+
valid: !1,
|
|
676
|
+
errors: [{ message: "Invalid geometries: geometries must be a non empty array", path: t }],
|
|
677
|
+
warnings: []
|
|
678
|
+
};
|
|
679
|
+
}
|
|
680
|
+
function G(e, t = "") {
|
|
681
|
+
if (!i.nonEmptyObject(e))
|
|
682
|
+
return {
|
|
683
|
+
valid: !1,
|
|
684
|
+
errors: [{ message: "Invalid geometry: geometry must be a non empty object", path: t }],
|
|
685
|
+
warnings: []
|
|
686
|
+
};
|
|
687
|
+
const n = `${t}/coordinates`;
|
|
688
|
+
let r;
|
|
689
|
+
switch (e.type) {
|
|
690
|
+
case p.POINT: {
|
|
691
|
+
const s = I(e.coordinates);
|
|
692
|
+
r = {
|
|
693
|
+
valid: s.valid,
|
|
694
|
+
errors: s.errors.map((a) => ({ ...a, path: n })),
|
|
695
|
+
warnings: s.warnings.map((a) => ({ ...a, path: n }))
|
|
696
|
+
};
|
|
697
|
+
break;
|
|
698
|
+
}
|
|
699
|
+
case p.MULTI_POINT: {
|
|
700
|
+
r = U(e.coordinates, 0, n);
|
|
701
|
+
break;
|
|
702
|
+
}
|
|
703
|
+
case p.LINESTRING: {
|
|
704
|
+
r = z(e.coordinates, n);
|
|
705
|
+
break;
|
|
706
|
+
}
|
|
707
|
+
case p.MULTI_LINESTRING: {
|
|
708
|
+
r = Fe(e.coordinates, n);
|
|
709
|
+
break;
|
|
710
|
+
}
|
|
711
|
+
case p.POLYGON: {
|
|
712
|
+
r = Q(e.coordinates, n);
|
|
713
|
+
break;
|
|
714
|
+
}
|
|
715
|
+
case p.MULTI_POLYGON: {
|
|
716
|
+
r = Pe(e.coordinates, n);
|
|
717
|
+
break;
|
|
718
|
+
}
|
|
719
|
+
case p.GEOMETRY_COLLECTION: {
|
|
720
|
+
r = He(e.geometries, `${t}/geometries`);
|
|
721
|
+
break;
|
|
722
|
+
}
|
|
723
|
+
default:
|
|
724
|
+
return {
|
|
725
|
+
valid: !1,
|
|
726
|
+
errors: [{ message: `Invalid geometry type: ${e.type}`, path: t }],
|
|
727
|
+
warnings: []
|
|
728
|
+
};
|
|
729
|
+
}
|
|
730
|
+
return A(e, r, t);
|
|
731
|
+
}
|
|
732
|
+
function X(e, t = "") {
|
|
733
|
+
if (!i.nonEmptyObject(e))
|
|
734
|
+
return {
|
|
735
|
+
valid: !1,
|
|
736
|
+
errors: [{ message: "Invalid feature: must be a non empty object", path: t }],
|
|
737
|
+
warnings: []
|
|
738
|
+
};
|
|
739
|
+
if (e.type === h.FEATURE) {
|
|
740
|
+
if (i.nonEmptyObject(e.geometry)) {
|
|
741
|
+
const n = G(e.geometry, `${t}/geometry`);
|
|
742
|
+
return A(e, n, t);
|
|
743
|
+
}
|
|
744
|
+
return {
|
|
745
|
+
valid: !0,
|
|
746
|
+
errors: [],
|
|
747
|
+
warnings: [{ message: "Feature has no geometry", path: t }]
|
|
748
|
+
};
|
|
749
|
+
}
|
|
750
|
+
if (e.type === h.FEATURE_COLLECTION) {
|
|
751
|
+
if (i.nonEmptyArray(e.features)) {
|
|
752
|
+
const n = b(e.features, X, `${t}/features`);
|
|
753
|
+
return A(e, n, t);
|
|
754
|
+
}
|
|
755
|
+
return {
|
|
756
|
+
valid: !1,
|
|
757
|
+
errors: [{ message: "Invalid FeatureCollection: features must be a non empty array", path: t }],
|
|
758
|
+
warnings: []
|
|
759
|
+
};
|
|
760
|
+
}
|
|
761
|
+
return {
|
|
762
|
+
valid: !1,
|
|
763
|
+
errors: [{ message: `Invalid feature: unknown type: ${e.type}`, path: t }],
|
|
764
|
+
warnings: []
|
|
765
|
+
};
|
|
766
|
+
}
|
|
767
|
+
function at(e) {
|
|
768
|
+
if (l.that(e, i.nonEmptyObject, "geojson must be a non empty object"), i.oneOf(e.type, Object.values(p))) return G(e, "");
|
|
769
|
+
if (e.type === h.FEATURE || e.type === h.FEATURE_COLLECTION) {
|
|
770
|
+
const t = X(e, "");
|
|
771
|
+
return xe(e, t);
|
|
772
|
+
}
|
|
773
|
+
return {
|
|
774
|
+
valid: !1,
|
|
775
|
+
errors: [{ message: "Invalid GeoJson: type must be either a Geometry, a Feature or a FeatureCollection" }],
|
|
776
|
+
warnings: []
|
|
777
|
+
};
|
|
778
|
+
}
|
|
779
|
+
export {
|
|
780
|
+
d as AXES,
|
|
781
|
+
N as COORDINATE_FORMATS,
|
|
782
|
+
be as COORDINATE_MODELS,
|
|
783
|
+
_ as COORDINATE_TRUNCATION_FACTORS,
|
|
784
|
+
D as CRS_TYPES,
|
|
785
|
+
h as FEATURE_TYPES,
|
|
786
|
+
p as GEOMETRY_TYPES,
|
|
787
|
+
et as convertCoordinate,
|
|
788
|
+
H as getCoordinatePrecision,
|
|
789
|
+
ae as getDirectionAxis,
|
|
790
|
+
Ye as getDirections,
|
|
791
|
+
Qe as getEast,
|
|
792
|
+
ie as getLocale,
|
|
793
|
+
qe as getNorth,
|
|
794
|
+
ze as getSouth,
|
|
795
|
+
Xe as getWest,
|
|
796
|
+
P as guessCoordinateAxis,
|
|
797
|
+
We as isAltitude,
|
|
798
|
+
Z as isAxis,
|
|
799
|
+
v as isDirection,
|
|
800
|
+
j as isEast,
|
|
801
|
+
R as isLatitude,
|
|
802
|
+
Te as isLikeBBox,
|
|
803
|
+
nt as isLikeCRS,
|
|
804
|
+
De as isLikeFeature,
|
|
805
|
+
Ie as isLikeFeatureCollection,
|
|
806
|
+
rt as isLikeGeoJson,
|
|
807
|
+
Le as isLikeGeometry,
|
|
808
|
+
Se as isLikePosition,
|
|
809
|
+
W as isLongitude,
|
|
810
|
+
se as isNorth,
|
|
811
|
+
B as isSouth,
|
|
812
|
+
$ as isWest,
|
|
813
|
+
Be as listLocales,
|
|
814
|
+
Je as normalizeCoordinate,
|
|
815
|
+
Oe as parseCoordinate,
|
|
816
|
+
tt as parsePosition,
|
|
817
|
+
je as registerLocale,
|
|
818
|
+
Ke as setLocale,
|
|
819
|
+
it as truncateBBox,
|
|
820
|
+
Ze as truncateCoordinate,
|
|
821
|
+
st as truncatePosition,
|
|
822
|
+
Re as validateBBox,
|
|
823
|
+
we as validateCRS,
|
|
824
|
+
at as validateGeoJson,
|
|
825
|
+
G as validateGeometry,
|
|
826
|
+
I as validatePosition
|
|
827
|
+
};
|
|
828
|
+
//# sourceMappingURL=index.mjs.map
|