@tak-ps/node-cot 14.59.0 → 14.60.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 (76) hide show
  1. package/.oxlintrc.json +100 -0
  2. package/CHANGELOG.md +5 -0
  3. package/README.md +13 -0
  4. package/cli.ts +21 -22
  5. package/dist/cli.js +18 -19
  6. package/dist/cli.js.map +1 -1
  7. package/dist/lib/builders/chat.d.ts +4 -4
  8. package/dist/lib/builders/chat.js +3 -6
  9. package/dist/lib/builders/chat.js.map +1 -1
  10. package/dist/lib/builders/route.js +2 -2
  11. package/dist/lib/cot.js +44 -56
  12. package/dist/lib/cot.js.map +1 -1
  13. package/dist/lib/data-package.d.ts +3 -3
  14. package/dist/lib/data-package.js +68 -81
  15. package/dist/lib/data-package.js.map +1 -1
  16. package/dist/lib/parser/from_geojson.js +24 -30
  17. package/dist/lib/parser/from_geojson.js.map +1 -1
  18. package/dist/lib/parser/normalize_geojson.js +22 -22
  19. package/dist/lib/parser/normalize_geojson.js.map +1 -1
  20. package/dist/lib/parser/to_geojson.js +94 -86
  21. package/dist/lib/parser/to_geojson.js.map +1 -1
  22. package/dist/lib/parser-normalize.d.ts +5 -0
  23. package/dist/lib/parser-normalize.js +25 -8
  24. package/dist/lib/parser-normalize.js.map +1 -1
  25. package/dist/lib/parser.js +96 -81
  26. package/dist/lib/parser.js.map +1 -1
  27. package/dist/lib/sensor.js +11 -5
  28. package/dist/lib/sensor.js.map +1 -1
  29. package/dist/lib/type.js +5 -10
  30. package/dist/lib/type.js.map +1 -1
  31. package/dist/lib/types/cot-types.js +4 -4
  32. package/dist/lib/types/cot-types.js.map +1 -1
  33. package/dist/lib/types/feature.d.ts +755 -755
  34. package/dist/lib/types/types.d.ts +55 -9
  35. package/dist/lib/types/types.js +18 -3
  36. package/dist/lib/types/types.js.map +1 -1
  37. package/dist/lib/utils/2525.js +139 -92
  38. package/dist/lib/utils/2525.js.map +1 -1
  39. package/dist/lib/utils/color.js +1 -1
  40. package/dist/lib/utils/color.js.map +1 -1
  41. package/dist/lib/utils/type.js +5 -10
  42. package/dist/lib/utils/type.js.map +1 -1
  43. package/dist/lib/utils/util.d.ts +5 -0
  44. package/dist/lib/utils/util.js +25 -16
  45. package/dist/lib/utils/util.js.map +1 -1
  46. package/dist/lib/xml/basemap.js +10 -9
  47. package/dist/lib/xml/basemap.js.map +1 -1
  48. package/dist/lib/xml/iconset.js +1 -1
  49. package/dist/lib/xml/iconset.js.map +1 -1
  50. package/dist/lib/xml-document.d.ts +1 -1
  51. package/dist/lib/xml-document.js +6 -3
  52. package/dist/lib/xml-document.js.map +1 -1
  53. package/dist/package.json +7 -7
  54. package/dist/tsconfig.tsbuildinfo +1 -1
  55. package/lib/builders/chat.ts +3 -3
  56. package/lib/builders/route.ts +2 -2
  57. package/lib/cot.ts +42 -47
  58. package/lib/data-package.ts +72 -76
  59. package/lib/parser/from_geojson.ts +24 -29
  60. package/lib/parser/normalize_geojson.ts +22 -26
  61. package/lib/parser/to_geojson.ts +105 -94
  62. package/lib/parser-normalize.ts +30 -9
  63. package/lib/parser.ts +121 -92
  64. package/lib/sensor.ts +12 -5
  65. package/lib/type.ts +5 -5
  66. package/lib/types/cot-types.ts +4 -4
  67. package/lib/types/types.ts +20 -3
  68. package/lib/utils/2525.ts +147 -96
  69. package/lib/utils/color.ts +1 -1
  70. package/lib/utils/type.ts +5 -5
  71. package/lib/utils/util.ts +31 -15
  72. package/lib/xml/basemap.ts +10 -9
  73. package/lib/xml/iconset.ts +1 -1
  74. package/lib/xml-document.ts +7 -4
  75. package/package.json +7 -7
  76. package/eslint.config.js +0 -15
@@ -7,7 +7,7 @@ import StreamZip from 'node-stream-zip';
7
7
  import { Readable } from 'node:stream';
8
8
  import CoT from './cot.js';
9
9
  import { CoTParser } from './parser.js';
10
- import xmljs from '@tak-ps/xml-js';
10
+ import { xml2js, js2xml } from '@tak-ps/xml-js';
11
11
  import os from 'node:os';
12
12
  import fs from 'node:fs';
13
13
  import fsp from 'node:fs/promises';
@@ -111,7 +111,7 @@ export class DataPackage {
111
111
  * @param opts Optional Options
112
112
  */
113
113
  constructor(uid, name, opts = {}) {
114
- if (opts && opts.path) {
114
+ if (opts?.path) {
115
115
  this.path = opts.path;
116
116
  }
117
117
  else {
@@ -160,13 +160,14 @@ export class DataPackage {
160
160
  }
161
161
  };
162
162
  for (const key in this.settings) {
163
- if (!this.settings[key])
163
+ const value = this.settings[key];
164
+ if (value === undefined || value === false || value === '')
164
165
  continue;
165
166
  manifest.MissionPackageManifest.Configuration.Parameter.push({
166
- _attributes: { name: key, value: String(this.settings[key]) }
167
+ _attributes: { name: key, value: String(value) }
167
168
  });
168
169
  }
169
- const xml = `<?xml version="1.0" encoding="UTF-8"?>\n${xmljs.js2xml(manifest, { compact: true })}`;
170
+ const xml = `<?xml version="1.0" encoding="UTF-8"?>\n${js2xml(manifest, { compact: true })}`;
170
171
  return xml;
171
172
  }
172
173
  /**
@@ -174,14 +175,14 @@ export class DataPackage {
174
175
  * Return true if the DataPackage is a MissionSync Archive
175
176
  */
176
177
  isMissionArchive() {
177
- return !!(this.settings.mission_guid && this.settings.mission_name);
178
+ return Boolean(this.settings.mission_guid) && Boolean(this.settings.mission_name);
178
179
  }
179
180
  /**
180
181
  * When DataPackages are uploaded to TAK Server they generally use an EUD
181
182
  * calculated Hash
182
183
  */
183
- static async hash(path) {
184
- const input = fs.createReadStream(path);
184
+ static async hash(file) {
185
+ const input = fs.createReadStream(file);
185
186
  const hash = createHash('sha256');
186
187
  await pipeline(input, hash);
187
188
  return hash.digest('hex');
@@ -191,7 +192,7 @@ export class DataPackage {
191
192
  * calculated Hash
192
193
  */
193
194
  async hash(entry) {
194
- return await DataPackage.hash(this.path + '/raw/' + entry);
195
+ return DataPackage.hash(this.path + '/raw/' + entry);
195
196
  }
196
197
  /**
197
198
  * Return a DataPackage version of a raw Data Package Zip
@@ -204,12 +205,9 @@ export class DataPackage {
204
205
  * @param [opts.name] Optional input filename used for manifest-less archives when parsing from in-memory data
205
206
  */
206
207
  static async parse(input, opts) {
207
- if (!opts)
208
- opts = {};
209
- if (opts.strict === undefined)
210
- opts.strict = true;
211
- if (opts.cleanup === undefined)
212
- opts.cleanup = true;
208
+ opts ??= {};
209
+ opts.strict ??= true;
210
+ opts.cleanup ??= true;
213
211
  const source = await materializeDataPackageInput(input, opts.name);
214
212
  const pkg = new DataPackage();
215
213
  const zip = new StreamZip.async({
@@ -217,17 +215,18 @@ export class DataPackage {
217
215
  skipEntryNameValidation: true
218
216
  });
219
217
  const preentries = await zip.entries();
220
- if (opts.strict && !preentries['MANIFEST/manifest.xml']) {
218
+ const manifestEntry = preentries['MANIFEST/manifest.xml'];
219
+ if (opts.strict && manifestEntry === undefined) {
221
220
  throw new Err(400, null, 'No MANIFEST/manifest.xml found in Data Package');
222
221
  }
223
222
  await fsp.mkdir(pkg.path + '/raw', { recursive: true });
224
223
  await zip.extract(null, pkg.path + '/raw/');
225
- if (preentries['MANIFEST/manifest.xml']) {
226
- const xml = xmljs.xml2js(String(await fsp.readFile(pkg.path + '/raw/MANIFEST/manifest.xml')), { compact: true });
227
- checkManifest(xml);
228
- if (checkManifest.errors)
229
- throw new Err(400, null, `${checkManifest.errors[0].message} (${checkManifest.errors[0].instancePath})`);
230
- const manifest = xml;
224
+ if (manifestEntry !== undefined) {
225
+ const manifest = xml2js(String(await fsp.readFile(pkg.path + '/raw/MANIFEST/manifest.xml')), { compact: true });
226
+ if (!checkManifest(manifest)) {
227
+ const [error] = checkManifest.errors ?? [];
228
+ throw new Err(400, null, `${error?.message} (${error?.instancePath})`);
229
+ }
231
230
  pkg.version = manifest.MissionPackageManifest._attributes.version;
232
231
  if (Array.isArray(manifest.MissionPackageManifest.Contents.Content)) {
233
232
  pkg.contents = manifest.MissionPackageManifest.Contents.Content;
@@ -237,7 +236,7 @@ export class DataPackage {
237
236
  }
238
237
  for (const param of manifest.MissionPackageManifest.Configuration.Parameter) {
239
238
  if (['onReceiveImport', 'onReceiveDelete'].includes(param._attributes.name) && typeof param._attributes.value === 'string') {
240
- pkg.settings[param._attributes.name] = param._attributes.value === 'false' ? false : true;
239
+ pkg.settings[param._attributes.name] = param._attributes.value !== 'false';
241
240
  }
242
241
  else {
243
242
  pkg.settings[param._attributes.name] = param._attributes.value;
@@ -269,7 +268,7 @@ export class DataPackage {
269
268
  #addContent(zipEntry, uid, name, ignore = false) {
270
269
  if (this.destroyed)
271
270
  throw new Err(400, null, 'Attempt to access Data Package after it has been destroyed');
272
- // TODO: Seen in the wild but not currently implemented here:
271
+ // Seen in the wild but not currently implemented here:
273
272
  // <Parameter name="contentType" value="KML"/>
274
273
  // <Parameter name="visible" value="false"/>
275
274
  this.contents.push({
@@ -289,43 +288,36 @@ export class DataPackage {
289
288
  other attachment actions do not automatically populate this field other than the link
290
289
  provided between a CoT and it's attachment in the MANIFEST file
291
290
  */
292
- async cots(opts = {
293
- respectIgnore: true,
294
- parseAttachments: true
295
- }) {
291
+ async cots(opts) {
296
292
  if (this.destroyed)
297
293
  throw new Err(400, null, 'Attempt to access Data Package after it has been destroyed');
294
+ const respectIgnore = opts ? opts.respectIgnore : true;
295
+ const parseAttachments = opts ? opts.parseAttachments : true;
298
296
  const cotsMap = new Map();
299
297
  const cots = [];
300
298
  for (const content of this.contents) {
301
- if (!content)
302
- continue;
303
299
  if (path.parse(content._attributes.zipEntry).ext !== '.cot')
304
300
  continue;
305
- if (opts.respectIgnore && content._attributes.ignore)
301
+ if (respectIgnore && content._attributes.ignore)
306
302
  continue;
307
303
  const cot = CoTParser.from_xml(await fsp.readFile(this.path + '/raw/' + content._attributes.zipEntry));
308
304
  cotsMap.set(cot.uid(), cot);
309
305
  cots.push(cot);
310
306
  }
311
- if (opts.parseAttachments) {
312
- const attachments = this.#attachments(cotsMap, {
313
- respectIgnore: opts.respectIgnore
314
- });
307
+ if (parseAttachments) {
308
+ const attachments = this.#attachments(cotsMap, { respectIgnore });
315
309
  for (const cot of cots) {
316
- if (!cot.raw.event.detail) {
317
- cot.raw.event.detail = {};
318
- }
310
+ cot.raw.event.detail ??= {};
319
311
  const attaches = attachments.get(cot.uid());
320
312
  if (!attaches)
321
313
  continue;
322
314
  for (const attach of attaches) {
323
- if (!cot.raw.event.detail.attachment_list) {
324
- cot.raw.event.detail.attachment_list = {
325
- _attributes: { hashes: '[]' }
326
- };
327
- }
315
+ cot.raw.event.detail.attachment_list ??= {
316
+ _attributes: { hashes: '[]' }
317
+ };
328
318
  const hashes = JSON.parse(cot.raw.event.detail.attachment_list._attributes.hashes);
319
+ if (!Array.isArray(hashes))
320
+ throw new Err(400, null, 'attachment_list hashes must be a JSON Array');
329
321
  // Until told otherwise the FileHash appears to always be the directory name
330
322
  const hash = await this.hash(attach._attributes.zipEntry);
331
323
  if (!hashes.includes(hash)) {
@@ -337,29 +329,27 @@ export class DataPackage {
337
329
  }
338
330
  return cots;
339
331
  }
340
- #attachments(cots, opts = { respectIgnore: true }) {
332
+ #attachments(cots, opts) {
341
333
  const attachments = new Map();
342
334
  for (const content of this.contents) {
343
- if (!content)
344
- continue;
345
335
  if (path.parse(content._attributes.zipEntry).ext === '.cot')
346
336
  continue;
347
337
  if (opts.respectIgnore && content._attributes.ignore)
348
338
  continue;
349
- if (content.Parameter) {
350
- const params = Array.isArray(content.Parameter) ? content.Parameter : [content.Parameter];
351
- for (const param of params) {
352
- if (param._attributes.name === 'uid' && cots.has(param._attributes.value)) {
353
- const existing = attachments.get(param._attributes.value);
354
- if (existing) {
355
- existing.push(content);
356
- }
357
- else {
358
- attachments.set(param._attributes.value, [content]);
359
- }
360
- break;
361
- }
339
+ if (!content.Parameter)
340
+ continue;
341
+ const params = Array.isArray(content.Parameter) ? content.Parameter : [content.Parameter];
342
+ for (const param of params) {
343
+ if (param._attributes.name !== 'uid' || !cots.has(param._attributes.value))
344
+ continue;
345
+ const existing = attachments.get(param._attributes.value);
346
+ if (existing) {
347
+ existing.push(content);
362
348
  }
349
+ else {
350
+ attachments.set(param._attributes.value, [content]);
351
+ }
352
+ break;
363
353
  }
364
354
  }
365
355
  return attachments;
@@ -368,8 +358,9 @@ export class DataPackage {
368
358
  * Return a list of files that are NOT attachments or CoT markers
369
359
  * The Set returned has a list of file paths that can be passed to getFile(path)
370
360
  */
371
- async files(opts = { respectIgnore: true }) {
372
- const attachments = await this.attachments(opts);
361
+ async files(opts) {
362
+ const respectIgnore = opts ? opts.respectIgnore : true;
363
+ const attachments = await this.attachments({ respectIgnore });
373
364
  const files = new Set();
374
365
  const attachment_entries = new Set();
375
366
  for (const entries of attachments.values()) {
@@ -378,11 +369,9 @@ export class DataPackage {
378
369
  }
379
370
  }
380
371
  for (const content of this.contents) {
381
- if (!content)
382
- continue;
383
372
  if (path.parse(content._attributes.zipEntry).ext === '.cot')
384
373
  continue;
385
- if (opts.respectIgnore && content._attributes.ignore)
374
+ if (respectIgnore && content._attributes.ignore)
386
375
  continue;
387
376
  if (attachment_entries.has(content._attributes.zipEntry)) {
388
377
  continue;
@@ -395,40 +384,41 @@ export class DataPackage {
395
384
  * Return attachments that are associated in the Manifest with a given CoT
396
385
  * Note: this does not return files that are NOT associated with a CoT
397
386
  */
398
- async attachments(opts = { respectIgnore: true }) {
387
+ async attachments(opts) {
388
+ const respectIgnore = opts ? opts.respectIgnore : true;
399
389
  const cots = new Map();
400
390
  for (const cot of await this.cots({
401
- respectIgnore: opts.respectIgnore,
391
+ respectIgnore,
402
392
  parseAttachments: false
403
393
  })) {
404
394
  cots.set(cot.uid(), cot);
405
395
  }
406
- return this.#attachments(cots, opts);
396
+ return this.#attachments(cots, { respectIgnore });
407
397
  }
408
- async getFileBuffer(path) {
398
+ async getFileBuffer(file) {
409
399
  if (this.destroyed)
410
400
  throw new Err(400, null, 'Attempt to access Data Package after it has been destroyed');
411
401
  try {
412
- await fsp.access(`${this.path}/raw/${path}`);
402
+ await fsp.access(`${this.path}/raw/${file}`);
413
403
  }
414
404
  catch (err) {
415
405
  throw new Err(400, err instanceof Error ? err : new Error(String(err)), 'Could not access file in Data Package');
416
406
  }
417
- return await fsp.readFile(`${this.path}/raw/${path}`);
407
+ return fsp.readFile(`${this.path}/raw/${file}`);
418
408
  }
419
409
  /**
420
410
  * Get any file from a Package
421
411
  */
422
- async getFile(path) {
412
+ async getFile(file) {
423
413
  if (this.destroyed)
424
414
  throw new Err(400, null, 'Attempt to access Data Package after it has been destroyed');
425
415
  try {
426
- await fsp.access(`${this.path}/raw/${path}`);
416
+ await fsp.access(`${this.path}/raw/${file}`);
427
417
  }
428
418
  catch (err) {
429
419
  throw new Err(400, err instanceof Error ? err : new Error(String(err)), 'Could not access file in Data Package');
430
420
  }
431
- return fs.createReadStream(`${this.path}/raw/${path}`);
421
+ return fs.createReadStream(`${this.path}/raw/${file}`);
432
422
  }
433
423
  /**
434
424
  * Add any file to a Package
@@ -443,8 +433,7 @@ export class DataPackage {
443
433
  async addFile(file, opts) {
444
434
  if (this.destroyed)
445
435
  throw new Err(400, null, 'Attempt to access Data Package after it has been destroyed');
446
- if (!opts.ignore)
447
- opts.ignore = false;
436
+ opts.ignore ??= false;
448
437
  const uid = opts.uid ?? crypto.randomUUID();
449
438
  this.#addContent(`${uid}/${opts.name}`, opts.attachment || uid, opts.name, opts.ignore);
450
439
  await fsp.mkdir(`${this.path}/raw/${uid}/`, { recursive: true });
@@ -453,13 +442,11 @@ export class DataPackage {
453
442
  /**
454
443
  * Add a CoT marker to the Package
455
444
  */
456
- async addCoT(cot, opts = {
457
- ignore: false
458
- }) {
445
+ async addCoT(cot, opts) {
459
446
  if (this.destroyed)
460
447
  throw new Err(400, null, 'Attempt to access Data Package after it has been destroyed');
461
448
  const name = cot.callsign();
462
- this.#addContent(`${cot.raw.event._attributes.uid}/${cot.raw.event._attributes.uid}.cot`, cot.raw.event._attributes.uid, name, opts.ignore);
449
+ this.#addContent(`${cot.raw.event._attributes.uid}/${cot.raw.event._attributes.uid}.cot`, cot.raw.event._attributes.uid, name, opts?.ignore);
463
450
  await fsp.mkdir(`${this.path}/raw/${cot.raw.event._attributes.uid}/`, { recursive: true });
464
451
  await fsp.writeFile(`${this.path}/raw/${cot.raw.event._attributes.uid}/${cot.raw.event._attributes.uid}.cot`, CoTParser.to_xml(cot));
465
452
  }
@@ -485,10 +472,10 @@ export class DataPackage {
485
472
  const output = fs.createWriteStream(this.path + `/${this.settings.uid}.zip`);
486
473
  archive.pipe(output);
487
474
  output.on('close', () => {
488
- return resolve(this.path + `/${this.settings.uid}.zip`);
475
+ resolve(this.path + `/${this.settings.uid}.zip`);
489
476
  });
490
477
  archive.directory(this.path + '/raw/', '/');
491
- archive.finalize();
478
+ void archive.finalize();
492
479
  });
493
480
  }
494
481
  }
@@ -1 +1 @@
1
- {"version":3,"file":"data-package.js","sourceRoot":"","sources":["../../lib/data-package.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAA;AACxC,OAAO,GAAG,MAAM,4BAA4B,CAAC;AAC7C,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,SAAS,MAAM,iBAAiB,CAAA;AACvC,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,GAAG,MAAM,UAAU,CAAC;AAC3B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,KAAK,MAAM,gBAAgB,CAAC;AACnC,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,GAAG,MAAM,kBAAkB,CAAC;AACnC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,GAAG,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,SAAS,GAAG,IAAI,CAAC,MAAM,CAAC;IACjC,WAAW,EAAE,IAAI,CAAC,MAAM,CAAC;QACrB,IAAI,E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EAAE,EAAE;YAC3B,MAAM,OAAO,GAAG,IAAI,UAAU,CAAC,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;YACvD,MAAM,MAAM,GAAG,EAAE,CAAC,iBAAiB,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,MAAM,CAAC,CAAA;YAC5E,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;YACrB,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,EAAE;gBACpB,OAAO,CAAC,IAAI,CAAC,IAAI,GAAG,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,MAAM,CAAC,CAAC;YACrD,CAAC,CAAC,CAAC;YACH,OAAO,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,GAAG,OAAO,EAAE,GAAG,CAAC,CAAC;YAC5C,KAAK,OAAO,CAAC,QAAQ,EAAE,CAAA;QAC3B,CAAC,CAAC,CAAC;IACP,CAAC;CACJ"}
@@ -3,7 +3,7 @@ import { InputFeature, } from '../types/feature.js';
3
3
  import TypeValidator from '../type.js';
4
4
  import Type2525 from '../utils/2525.js';
5
5
  import PointOnFeature from '@turf/point-on-feature';
6
- import Util from '../utils/util.js';
6
+ import Util, { jsonClone } from '../utils/util.js';
7
7
  import Color from '../utils/color.js';
8
8
  import JSONCoT from '../types/types.js';
9
9
  import CoT from '../cot.js';
@@ -18,20 +18,18 @@ const ELLIPSE_TYPES = new Set(['u-d-c-c', 'u-r-b-c-c', 'u-d-c-e']);
18
18
  export async function from_geojson(feature, opts = {}) {
19
19
  const explicitType = typeof feature.properties?.type === 'string';
20
20
  try {
21
- feature = await TypeValidator.type(InputFeature, feature, {
21
+ feature = TypeValidator.type(InputFeature, feature, {
22
22
  verbose: opts.verbose
23
23
  });
24
24
  }
25
25
  catch (err) {
26
- throw new Err(400, null, `Validation Error: ${err}`);
26
+ throw new Err(400, null, `Validation Error: ${String(err)}`);
27
27
  }
28
28
  // The type property can either be a traditional CoT Type or a numeric 2525D/2525E SIDC
29
29
  if (feature.properties.type && Type2525.isNumericSIDCConvertable(feature.properties.type)) {
30
- if (!feature.properties.milicon) {
31
- feature.properties.milicon = {
32
- id: feature.properties.type
33
- };
34
- }
30
+ feature.properties.milicon ??= {
31
+ id: feature.properties.type
32
+ };
35
33
  feature.properties.type = Type2525.cotTypeFromNumericSIDC(feature.properties.type);
36
34
  }
37
35
  const cot = {
@@ -42,13 +40,12 @@ export async function from_geojson(feature, opts = {}) {
42
40
  }
43
41
  };
44
42
  if (feature.id) {
45
- cot.event._attributes.uid = String(feature.id);
43
+ cot.event._attributes.uid = feature.id;
46
44
  }
47
45
  else {
48
46
  cot.event._attributes.uid = crypto.randomUUID();
49
47
  }
50
- if (!cot.event.detail)
51
- cot.event.detail = {};
48
+ cot.event.detail ??= {};
52
49
  if (feature.properties.droid) {
53
50
  cot.event.detail.uid = { _attributes: { Droid: feature.properties.droid } };
54
51
  }
@@ -76,8 +73,8 @@ export async function from_geojson(feature, opts = {}) {
76
73
  }
77
74
  if (feature.properties.dest) {
78
75
  const dest = !Array.isArray(feature.properties.dest) ? [feature.properties.dest] : feature.properties.dest;
79
- cot.event.detail.marti.dest = dest.map((dest) => {
80
- return { _attributes: { ...dest } };
76
+ cot.event.detail.marti.dest = dest.map((d) => {
77
+ return { _attributes: { ...d } };
81
78
  });
82
79
  }
83
80
  }
@@ -126,7 +123,7 @@ export async function from_geojson(feature, opts = {}) {
126
123
  if (feature.properties.minzoom !== undefined
127
124
  || feature.properties.maxzoom !== undefined
128
125
  || feature.properties.rotate !== undefined) {
129
- if (!cot.event.detail.display || !cot.event.detail.display._attributes) {
126
+ if (!cot.event.detail.display?._attributes) {
130
127
  cot.event.detail.display = { _attributes: {} };
131
128
  }
132
129
  if (feature.properties.minzoom !== undefined) {
@@ -233,8 +230,8 @@ export async function from_geojson(feature, opts = {}) {
233
230
  }
234
231
  if (feature.properties.video) {
235
232
  if (feature.properties.video.connection) {
236
- const video = JSON.parse(JSON.stringify(feature.properties.video));
237
- const connection = video.connection;
233
+ const video = jsonClone(feature.properties.video);
234
+ const connection = jsonClone(feature.properties.video.connection);
238
235
  delete video.connection;
239
236
  cot.event.detail.__video = {
240
237
  _attributes: { ...video },
@@ -325,10 +322,7 @@ export async function from_geojson(feature, opts = {}) {
325
322
  }
326
323
  }
327
324
  cot.event.detail.remarks = { _attributes: {}, _text: feature.properties.remarks || '' };
328
- if (!feature.geometry) {
329
- throw new Err(400, null, 'Must have Geometry');
330
- }
331
- else if (!['Point', 'Polygon', 'LineString'].includes(feature.geometry.type)) {
325
+ if (!['Point', 'Polygon', 'LineString'].includes(feature.geometry.type)) {
332
326
  throw new Err(400, null, 'Unsupported Geometry Type');
333
327
  }
334
328
  // This isn't specific to point as the color can apply to the centroid point
@@ -351,10 +345,12 @@ export async function from_geojson(feature, opts = {}) {
351
345
  const stroke = new Color(feature.properties.stroke || -1761607936);
352
346
  stroke.a = feature.properties['stroke-opacity'] !== undefined ? feature.properties['stroke-opacity'] * 255 : 128;
353
347
  cot.event.detail.strokeColor = { _attributes: { value: stroke.as_32bit() } };
354
- if (!feature.properties['stroke-width'])
355
- feature.properties['stroke-width'] = 3;
348
+ let strokeWidth = feature.properties['stroke-width'] ?? 0;
349
+ if (strokeWidth === 0)
350
+ strokeWidth = 3;
351
+ feature.properties['stroke-width'] = strokeWidth;
356
352
  cot.event.detail.strokeWeight = { _attributes: {
357
- value: feature.properties['stroke-width']
353
+ value: strokeWidth
358
354
  } };
359
355
  if (!feature.properties['stroke-style'])
360
356
  feature.properties['stroke-style'] = 'solid';
@@ -366,15 +362,13 @@ export async function from_geojson(feature, opts = {}) {
366
362
  fill.a = feature.properties['fill-opacity'] !== undefined ? feature.properties['fill-opacity'] * 255 : 128;
367
363
  cot.event.detail.fillColor = { _attributes: { value: fill.as_32bit() } };
368
364
  }
369
- else if (feature.geometry.type === 'LineString') {
365
+ else if (feature.geometry.type === 'LineString' && feature.properties.type !== 'b-m-r') {
370
366
  // Ensure fill is fully transparent for LineStrings so that if Node treats the
371
367
  // feature as a polygon (when first/last coordinates coincide), no fill is rendered.
372
368
  // Exclude b-m-r (route) types as they are not user-drawn line features.
373
- if (feature.properties.type !== 'b-m-r') {
374
- const fill = new Color(feature.properties.fill || -1761607936);
375
- fill.a = 0;
376
- cot.event.detail.fillColor = { _attributes: { value: fill.as_32bit() } };
377
- }
369
+ const fill = new Color(feature.properties.fill || -1761607936);
370
+ fill.a = 0;
371
+ cot.event.detail.fillColor = { _attributes: { value: fill.as_32bit() } };
378
372
  }
379
373
  if (feature.geometry.type === 'Polygon' && feature.properties.type && ELLIPSE_TYPES.has(feature.properties.type)) {
380
374
  if (!feature.properties.shape || !feature.properties.shape.ellipse) {
@@ -397,7 +391,7 @@ export async function from_geojson(feature, opts = {}) {
397
391
  Style: {
398
392
  LineStyle: {
399
393
  color: { _text: strokeColor.as_kml() },
400
- width: { _text: cot.event.detail.strokeWeight?._attributes?.value ? cot.event.detail.strokeWeight._attributes.value : 3 }
394
+ width: { _text: strokeWidth }
401
395
  },
402
396
  PolyStyle: {
403
397
  color: { _text: fillColor.as_kml() },