@nika-js/onlymap 0.2.3 → 0.3.1

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 (62) hide show
  1. package/.vscode/onlymap.code-snippets +13 -0
  2. package/LICENSE.md +4 -0
  3. package/README.md +30 -7
  4. package/THIRD-PARTY-LICENSES.md +7874 -0
  5. package/dist/{Arrow.dom-7AXne1TU.js → Arrow.dom-BNjbQ9jb.js} +23 -23
  6. package/dist/LercDecode.es-CVmNpXBp.js +303 -0
  7. package/dist/assets/LercDecode.es-BJb2dZu5.js +305 -0
  8. package/dist/assets/__vite-browser-external-DDArsqdc.js +29 -0
  9. package/dist/assets/lerc-wasm.wasm +0 -0
  10. package/dist/assets/lzw-BY5a_5nb.js +83 -0
  11. package/dist/assets/worker-DtIrTJB7.js +305 -0
  12. package/dist/assets/zstd-QGAv3PMm.js +383 -0
  13. package/dist/{basemap-BdvB-SHy.js → basemap-BSb-g03Z.js} +5729 -5684
  14. package/dist/basemap-registry.d.ts +10 -0
  15. package/dist/basemap.d.ts +23 -0
  16. package/dist/color.d.ts +9 -0
  17. package/dist/{convert-arrow-schema-CvZ3cT5m.js → convert-arrow-schema-DrAihRf9.js} +31 -31
  18. package/dist/ctx.d.ts +3 -0
  19. package/dist/deck.d.ts +28 -0
  20. package/dist/deck.js +16 -0
  21. package/dist/elements/om-map.d.ts +29 -0
  22. package/dist/html-data.d.ts +2 -2
  23. package/dist/index-CIEkseeV.js +3108 -0
  24. package/dist/index-D67FynN5.js +594 -0
  25. package/dist/{index-CJOMgp8k.js → index-QSkZjzIL.js} +4 -4
  26. package/dist/index-WeMwLoaQ.js +1446 -0
  27. package/dist/{index-BxzDKZpu.js → index-lV5eG2Xt.js} +22439 -21347
  28. package/dist/index.d.ts +13 -0
  29. package/dist/ir-snapshot.d.ts +2 -0
  30. package/dist/ir.d.ts +10 -0
  31. package/dist/layer-registry.d.ts +15 -1
  32. package/dist/legend-spec.d.ts +66 -0
  33. package/dist/lerc-DJzRIT6z.js +30 -0
  34. package/dist/lerc-wasm.wasm +0 -0
  35. package/dist/lzw-BY5a_5nb.js +83 -0
  36. package/dist/mgrs-BY9bIvp4.js +799 -0
  37. package/dist/onlymapjs.css +1 -1
  38. package/dist/onlymapjs.js +55 -35
  39. package/dist/programmatic.d.ts +35 -0
  40. package/dist/raster-BKf1dx54.js +8843 -0
  41. package/dist/raster.d.ts +61 -0
  42. package/dist/react/om-layer.d.ts +2 -0
  43. package/dist/react.js +18 -16
  44. package/dist/{recordbatch-HRu0SMKp.js → recordbatch-Bpc0uxFn.js} +200 -200
  45. package/dist/runtime-core.d.ts +73 -1
  46. package/dist/scene-lighting.d.ts +83 -0
  47. package/dist/selection.d.ts +1 -1
  48. package/dist/snapshot.d.ts +14 -0
  49. package/dist/{table-accessors-DBjWgN0C.js → table-accessors-CYWTzpQI.js} +71 -76
  50. package/dist/terrain.d.ts +113 -0
  51. package/dist/version.d.ts +1 -1
  52. package/dist/zstd-jXobGRcq.js +14 -0
  53. package/docs/custom-layers.md +99 -0
  54. package/llms.txt +5 -5
  55. package/onlymapjs.html-data.json +163 -29
  56. package/package.json +35 -15
  57. package/skills/onlymapjs/SKILL.md +3 -1
  58. package/skills/onlymapjs/references/syntax.md +53 -3
  59. package/dist/index-BVQ0s1Zh.js +0 -1457
  60. package/dist/index-CvBHiOGD.js +0 -605
  61. package/dist/index-Vc8QfNEf.js +0 -3907
  62. package/dist/onlymapjs.umd.cjs +0 -8634
@@ -1,5 +1,5 @@
1
- import { _ as Et, a as y, t as M, j as nt, b as di, c as hi, d as u, D as Tt, T as E, P as se, I as ht, U as pt, M as S, S as H, e as P, V as Gt, F, f as ie, g as re, h as ne, L as _s, B as bs, i as ps, k as ys, l as ms, m as gs, N as oe, n as ws, o as vs, p as Bs, q as Is, r as Ss, s as As, u as Fs, v as Ds, w as Os, x as Ms, y as Ls, z as fe, A as v, C as Qe, E as Ns, G as Rs, H as xs, J as _e, K as Mt, O as Pt, Q as be, R as De, W as G, X as ui, Y as m, Z as Us, $ as Oe, a0 as li, a1 as Ee, a2 as Ct, a3 as at, a4 as fi, a5 as Ts, a6 as Vs, a7 as _i, a8 as Xe, a9 as bi, aa as pi, ab as yi, ac as mi, ad as gi, ae as Me, af as Wt, ag as wi, ah as vi, ai as Bi, aj as Ii, ak as Si, al as Ai, am as Fi, an as Di, ao as Oi, ap as Mi, aq as Li, ar as Ni } from "./recordbatch-HRu0SMKp.js";
2
- import { as as Zr, at as Qr, au as Xr, av as tn, aw as en, ax as sn, ay as rn, az as nn, aA as on, aB as an, aC as cn, aD as dn, aE as hn, aF as un, aG as ln, aH as fn, aI as _n, aJ as bn, aK as pn, aL as yn, aM as mn, aN as gn, aO as wn, aP as vn, aQ as Bn, aR as In, aS as Sn, aT as An, aU as Fn, aV as Dn, aW as On, aX as Mn, aY as Ln, aZ as Nn, a_ as Rn, a$ as xn, b0 as Un, b1 as Tn, b2 as Vn, b3 as zn, b4 as En, b5 as Pn, b6 as jn, b7 as kn, b8 as Cn, b9 as Wn, ba as $n, bb as Jn, bc as Hn, bd as Yn, be as Gn, bf as qn, bg as Kn, bh as Zn, bi as Qn, bj as Xn, bk as to, bl as eo, bm as so, bn as io, bo as ro, bp as no, bq as oo, br as ao, bs as co, bt as ho, bu as uo, bv as lo, bw as fo, bx as _o, by as bo, bz as po, bA as yo, bB as mo, bC as go, bD as wo, bE as vo, bF as Bo, bG as Io, bH as So, bI as Ao, bJ as Fo, bK as Do, bL as Oo, bM as Mo, bN as Lo, bO as No, bP as Ro, bQ as xo, bR as Uo, bS as To } from "./recordbatch-HRu0SMKp.js";
1
+ import { _ as Et, G as y, H as M, J as nt, K as di, O as hi, P as u, Q as Tt, V as E, W as se, X as ht, Y as pt, Z as S, S as H, $ as P, a0 as Gt, F, u as ie, a1 as re, a as ne, L as _s, B as bs, a2 as ps, U as ys, a3 as ms, x as gs, N as oe, M as ws, b as vs, a4 as Bs, a5 as Is, a6 as Ss, a7 as As, a8 as Fs, a9 as Ds, aa as Os, D as Ms, ab as Ls, ac as fe, ad as v, ae as Qe, af as Ns, ag as Rs, ah as xs, ai as _e, aj as Mt, ak as Pt, al as be, am as De, an as G, ao as ui, C as m, ap as Us, aq as Oe, ar as li, as as Ee, R as Ct, at, au as fi, av as Ts, aw as Vs, ax as _i, ay as Xe, az as bi, aA as pi, aB as yi, aC as mi, aD as gi, aE as Me, A as Wt, aF as wi, aG as vi, y as Bi, aH as Ii, aI as Si, aJ as Ai, aK as Fi, aL as Di, aM as Oi, aN as Mi, aO as Li, aP as Ni } from "./recordbatch-Bpc0uxFn.js";
2
+ import { aQ as Zr, aR as Qr, z as Xr, aS as tn, l as en, aT as sn, k as rn, aU as nn, aV as on, aW as an, aX as cn, aY as dn, aZ as hn, a_ as un, a$ as ln, b0 as fn, b1 as _n, b2 as bn, b3 as pn, b4 as yn, b5 as mn, b6 as gn, b7 as wn, o as vn, b8 as Bn, n as In, b9 as Sn, m as An, ba as Fn, bb as Dn, v as On, bc as Mn, bd as Ln, t as Nn, be as Rn, w as xn, bf as Un, bg as Tn, bh as Vn, c as zn, bi as En, bj as Pn, bk as jn, I as kn, bl as Cn, bm as Wn, bn as $n, bo as Jn, bp as Hn, bq as Yn, br as Gn, bs as qn, bt as Kn, bu as Zn, bv as Qn, bw as Xn, h as to, bx as eo, i as so, by as io, g as ro, bz as no, j as oo, bA as ao, bB as co, d as ho, bC as uo, e as lo, bD as fo, T as _o, bE as bo, f as po, bF as yo, bG as mo, r as go, bH as wo, q as vo, bI as Bo, p as Io, bJ as So, s as Ao, bK as Fo, bL as Do, bM as Oo, bN as Mo, bO as Lo, bP as No, E as Ro, bQ as xo, bR as Uo, bS as To } from "./recordbatch-Bpc0uxFn.js";
3
3
  const V = {
4
4
  fromIterable(i) {
5
5
  return Zt(Ri(i));
@@ -2462,7 +2462,7 @@ class O {
2462
2462
  return this.headerType === _.DictionaryBatch;
2463
2463
  }
2464
2464
  constructor(t, e, s, r) {
2465
- this._version = e, this._headerType = s, this.body = new Uint8Array(0), this._compression = r == null ? void 0 : r.compression, r && (this._createHeader = () => r), this._bodyLength = P(t);
2465
+ this._version = e, this._headerType = s, this.body = new Uint8Array(0), this._compression = r?.compression, r && (this._createHeader = () => r), this._bodyLength = P(t);
2466
2466
  }
2467
2467
  }
2468
2468
  class L {
@@ -3537,13 +3537,13 @@ class Xs {
3537
3537
  );
3538
3538
  }
3539
3539
  readSchema(t = !1) {
3540
- const e = _.Schema, s = this.readMessage(e), r = s == null ? void 0 : s.header();
3540
+ const e = _.Schema, s = this.readMessage(e), r = s?.header();
3541
3541
  if (t && !r)
3542
3542
  throw new Error($e(e));
3543
3543
  return r;
3544
3544
  }
3545
3545
  readMetadataLength() {
3546
- const t = this.source.read(ye), e = t && new yt(t), s = (e == null ? void 0 : e.readInt32(0)) || 0;
3546
+ const t = this.source.read(ye), e = t && new yt(t), s = e?.readInt32(0) || 0;
3547
3547
  return { done: s === 0, value: s };
3548
3548
  }
3549
3549
  readMetadata(t) {
@@ -3604,7 +3604,7 @@ class wr {
3604
3604
  }
3605
3605
  readSchema() {
3606
3606
  return u(this, arguments, void 0, function* (t = !1) {
3607
- const e = _.Schema, s = yield this.readMessage(e), r = s == null ? void 0 : s.header();
3607
+ const e = _.Schema, s = yield this.readMessage(e), r = s?.header();
3608
3608
  if (t && !r)
3609
3609
  throw new Error($e(e));
3610
3610
  return r;
@@ -3612,7 +3612,7 @@ class wr {
3612
3612
  }
3613
3613
  readMetadataLength() {
3614
3614
  return u(this, void 0, void 0, function* () {
3615
- const t = yield this.source.read(ye), e = t && new yt(t), s = (e == null ? void 0 : e.readInt32(0)) || 0;
3615
+ const t = yield this.source.read(ye), e = t && new yt(t), s = e?.readInt32(0) || 0;
3616
3616
  return { done: s === 0, value: s };
3617
3617
  });
3618
3618
  }
@@ -3667,7 +3667,7 @@ class vr extends Xs {
3667
3667
  return e.value;
3668
3668
  }
3669
3669
  readSchema() {
3670
- const t = _.Schema, e = this.readMessage(t), s = e == null ? void 0 : e.header();
3670
+ const t = _.Schema, e = this.readMessage(t), s = e?.header();
3671
3671
  if (!e || !s)
3672
3672
  throw new Error($e(t));
3673
3673
  return s;
@@ -3731,7 +3731,7 @@ class Fr {
3731
3731
  this.registry = {};
3732
3732
  }
3733
3733
  set(t, e) {
3734
- if (e != null && e.encode && typeof e.encode == "function" && !Ar[t].isValidCodecEncode(e))
3734
+ if (e?.encode && typeof e.encode == "function" && !Ar[t].isValidCodecEncode(e))
3735
3735
  throw new Error(`Encoder for ${rt[t]} is not valid.`);
3736
3736
  this.registry[t] = e;
3737
3737
  }
@@ -3920,7 +3920,7 @@ class si {
3920
3920
  let s;
3921
3921
  if (t.compression != null) {
3922
3922
  const n = Te.get(t.compression.type);
3923
- if (n != null && n.decode && typeof n.decode == "function") {
3923
+ if (n?.decode && typeof n.decode == "function") {
3924
3924
  const { decommpressedBody: o, buffers: a } = this._decompressBuffers(t, e, n);
3925
3925
  s = this._loadCompressedVectors(t, o, this.schema.fields), t = new L(t.length, t.nodes, a, null);
3926
3926
  } else
@@ -3935,7 +3935,7 @@ class si {
3935
3935
  let d;
3936
3936
  if (t.data.compression != null) {
3937
3937
  const h = Te.get(t.data.compression.type);
3938
- if (h != null && h.decode && typeof h.decode == "function") {
3938
+ if (h?.decode && typeof h.decode == "function") {
3939
3939
  const { decommpressedBody: f, buffers: N } = this._decompressBuffers(t.data, e, h);
3940
3940
  d = this._loadCompressedVectors(t.data, f, [c]), t = new Y(new L(t.data.length, t.data.nodes, N, null), s, r);
3941
3941
  } else
@@ -4112,7 +4112,7 @@ class ii extends ue {
4112
4112
  const s = (e = this._footer) === null || e === void 0 ? void 0 : e.getRecordBatch(t);
4113
4113
  if (s && this._handle.seek(s.offset)) {
4114
4114
  const r = this._reader.readMessage(_.RecordBatch);
4115
- if (r != null && r.isRecordBatch()) {
4115
+ if (r?.isRecordBatch()) {
4116
4116
  const n = r.header(), o = this._reader.readMessageBody(r.bodyLength);
4117
4117
  return this._loadRecordBatch(n, o);
4118
4118
  }
@@ -4124,7 +4124,7 @@ class ii extends ue {
4124
4124
  const s = (e = this._footer) === null || e === void 0 ? void 0 : e.getDictionaryBatch(t);
4125
4125
  if (s && this._handle.seek(s.offset)) {
4126
4126
  const r = this._reader.readMessage(_.DictionaryBatch);
4127
- if (r != null && r.isDictionaryBatch()) {
4127
+ if (r?.isDictionaryBatch()) {
4128
4128
  const n = r.header(), o = this._reader.readMessageBody(r.bodyLength), a = this._loadDictionaryBatch(n, o);
4129
4129
  this.dictionaries.set(n.id, a);
4130
4130
  }
@@ -4186,7 +4186,7 @@ class Or extends le {
4186
4186
  const s = (e = this._footer) === null || e === void 0 ? void 0 : e.getRecordBatch(t);
4187
4187
  if (s && (yield this._handle.seek(s.offset))) {
4188
4188
  const r = yield this._reader.readMessage(_.RecordBatch);
4189
- if (r != null && r.isRecordBatch()) {
4189
+ if (r?.isRecordBatch()) {
4190
4190
  const n = r.header(), o = yield this._reader.readMessageBody(r.bodyLength);
4191
4191
  return this._loadRecordBatch(n, o);
4192
4192
  }
@@ -4200,7 +4200,7 @@ class Or extends le {
4200
4200
  const s = (e = this._footer) === null || e === void 0 ? void 0 : e.getDictionaryBatch(t);
4201
4201
  if (s && (yield this._handle.seek(s.offset))) {
4202
4202
  const r = yield this._reader.readMessage(_.DictionaryBatch);
4203
- if (r != null && r.isDictionaryBatch()) {
4203
+ if (r?.isDictionaryBatch()) {
4204
4204
  const n = r.header(), o = yield this._reader.readMessageBody(r.bodyLength), a = this._loadDictionaryBatch(n, o);
4205
4205
  this.dictionaries.set(n.id, a);
4206
4206
  }
@@ -4680,7 +4680,7 @@ class we extends Pe {
4680
4680
  }
4681
4681
  _compressBodyBuffers(t) {
4682
4682
  const e = Te.get(this._compression.type);
4683
- if (!(e != null && e.encode) || typeof e.encode != "function")
4683
+ if (!e?.encode || typeof e.encode != "function")
4684
4684
  throw new Error(`Codec for compression type "${rt[this._compression.type]}" has invalid encode method`);
4685
4685
  let s = 0;
4686
4686
  const r = [], n = [];
@@ -4722,7 +4722,7 @@ class we extends Pe {
4722
4722
  _writeDictionaries(t) {
4723
4723
  var e, s;
4724
4724
  for (const [r, n] of t.dictionaries) {
4725
- const o = (e = n == null ? void 0 : n.data) !== null && e !== void 0 ? e : [], a = this._seenDictionaries.get(r), c = (s = this._dictionaryDeltaOffsets.get(r)) !== null && s !== void 0 ? s : 0;
4725
+ const o = (e = n?.data) !== null && e !== void 0 ? e : [], a = this._seenDictionaries.get(r), c = (s = this._dictionaryDeltaOffsets.get(r)) !== null && s !== void 0 ? s : 0;
4726
4726
  if (!a || a.data[0] !== o[0])
4727
4727
  for (const [d, h] of o.entries())
4728
4728
  this._writeDictionaryBatch(h, r, d > 0);
@@ -4885,7 +4885,7 @@ function Pr(i, t) {
4885
4885
  }
4886
4886
  function jr(i, t) {
4887
4887
  let e = null;
4888
- const s = (t == null ? void 0 : t.type) === "bytes" || !1, r = (t == null ? void 0 : t.highWaterMark) || Math.pow(2, 24);
4888
+ const s = t?.type === "bytes" || !1, r = t?.highWaterMark || Math.pow(2, 24);
4889
4889
  return new ReadableStream(Object.assign(Object.assign({}, t), {
4890
4890
  start(o) {
4891
4891
  n(o, e || (e = i[Symbol.iterator]()));
@@ -4894,7 +4894,7 @@ function jr(i, t) {
4894
4894
  e ? n(o, e) : o.close();
4895
4895
  },
4896
4896
  cancel() {
4897
- e != null && e.return && e.return(), e = null;
4897
+ e?.return && e.return(), e = null;
4898
4898
  }
4899
4899
  }), Object.assign({ highWaterMark: s ? r : void 0 }, t));
4900
4900
  function n(o, a) {
@@ -4907,7 +4907,7 @@ function jr(i, t) {
4907
4907
  }
4908
4908
  function kr(i, t) {
4909
4909
  let e = null;
4910
- const s = (t == null ? void 0 : t.type) === "bytes" || !1, r = (t == null ? void 0 : t.highWaterMark) || Math.pow(2, 24);
4910
+ const s = t?.type === "bytes" || !1, r = t?.highWaterMark || Math.pow(2, 24);
4911
4911
  return new ReadableStream(Object.assign(Object.assign({}, t), {
4912
4912
  start(o) {
4913
4913
  return u(this, void 0, void 0, function* () {
@@ -4921,7 +4921,7 @@ function kr(i, t) {
4921
4921
  },
4922
4922
  cancel() {
4923
4923
  return u(this, void 0, void 0, function* () {
4924
- e != null && e.return && (yield e.return()), e = null;
4924
+ e?.return && (yield e.return()), e = null;
4925
4925
  });
4926
4926
  }
4927
4927
  }), Object.assign({ highWaterMark: s ? r : void 0 }, t));
@@ -4985,10 +4985,10 @@ class Wr {
4985
4985
  }
4986
4986
  const ls = (i) => {
4987
4987
  var t;
4988
- return (t = i == null ? void 0 : i.length) !== null && t !== void 0 ? t : 0;
4988
+ return (t = i?.length) !== null && t !== void 0 ? t : 0;
4989
4989
  }, fs = (i) => {
4990
4990
  var t;
4991
- return (t = i == null ? void 0 : i.byteLength) !== null && t !== void 0 ? t : 0;
4991
+ return (t = i?.byteLength) !== null && t !== void 0 ? t : 0;
4992
4992
  };
4993
4993
  function Ke(i, t) {
4994
4994
  const e = new kt();