@nika-js/onlymap 0.12.1 → 0.13.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 (61) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/README.md +1 -1
  3. package/dist/{basemap-BK25o5OE.js → basemap-zG1-omic.js} +473 -443
  4. package/dist/basemap.d.ts +16 -3
  5. package/dist/build-Bbi4SleC.js +208 -0
  6. package/dist/cartograph.js +43 -41
  7. package/dist/cartograph.standalone.js +3 -1
  8. package/dist/client-CIH6ToMI.js +6878 -0
  9. package/dist/{geoparquet-CLydPm2f.js → geoparquet-CyWsYt9S.js} +1 -1
  10. package/dist/{globe-view-ChuX60M5.js → globe-view-Xelgj_KW.js} +6 -6
  11. package/dist/{hillshade-DD8WFrvf.js → hillshade-Zbg50lm6.js} +79 -67
  12. package/dist/hillshade.d.ts +7 -0
  13. package/dist/html-data.d.ts +1 -1
  14. package/dist/{index-CgVFHEdM.js → index-6eeSlSqN.js} +3 -3
  15. package/dist/{index-CMKrghNb.js → index-BL_YCKiW.js} +54 -54
  16. package/dist/{index-C2CKUsom.js → index-BbVnkgld.js} +38 -38
  17. package/dist/{index-CvrH6mbS.js → index-BtRsa5oc.js} +3 -3
  18. package/dist/{index-DIzzRLKr.js → index-BwtXeP_F.js} +1 -1
  19. package/dist/{index-Dvwr1Y3o.js → index-ClAPAqcm.js} +49 -49
  20. package/dist/{index-Bs69fn8a.js → index-CpFNIkOO.js} +33429 -30673
  21. package/dist/{index-CdAf0bLj.js → index-DnCmvLuC.js} +42 -42
  22. package/dist/index-JFuN4DCn.js +4449 -0
  23. package/dist/layer-registry.d.ts +1 -0
  24. package/dist/{lerc-mAijS40k.js → lerc-C3SKC6CU.js} +1 -1
  25. package/dist/onlymap.standalone.js +60762 -51701
  26. package/dist/onlymapjs.js +47 -47
  27. package/dist/plane-gpu/gpu-layer-types.d.ts +35 -0
  28. package/dist/plane-gpu/plane-basemap.d.ts +10461 -0
  29. package/dist/plane-gpu/plane-gpu-view.d.ts +90 -0
  30. package/dist/plane-gpu/projection-params.d.ts +47 -0
  31. package/dist/plane-layers.d.ts +2 -0
  32. package/dist/plane-seam.d.ts +48 -0
  33. package/dist/plane-tileset.d.ts +23 -2
  34. package/dist/plane-vector/build.d.ts +107 -0
  35. package/dist/plane-vector/client.d.ts +18 -0
  36. package/dist/plane-vector/cut-ends-extension.d.ts +30 -0
  37. package/dist/plane-vector/plane-mvt-layer.d.ts +10412 -0
  38. package/dist/plane-vector/tile-cut.d.ts +45 -0
  39. package/dist/plane-vector/worker.d.ts +15 -0
  40. package/dist/plane-warp.d.ts +12 -1
  41. package/dist/{post-process-effect-rwFDi8di.js → post-process-effect-C3P9VwC9.js} +11 -11
  42. package/dist/programmatic.d.ts +6 -0
  43. package/dist/projection.d.ts +51 -0
  44. package/dist/{raster-CXIqf83L.js → raster-BgCnz9-Z.js} +3 -3
  45. package/dist/{raster-pipeline-CfSg2Re7.js → raster-pipeline-CKdpKgFo.js} +1 -1
  46. package/dist/react/om-map.d.ts +4 -0
  47. package/dist/react.js +259 -252
  48. package/dist/runtime-core.d.ts +84 -2
  49. package/dist/{text-on-path-B08PekFz.js → text-on-path-BpVLX8Yt.js} +74 -66
  50. package/dist/version.d.ts +1 -1
  51. package/dist/{zarr-CUn2udOc.js → zarr-Cur_pzNa.js} +2 -2
  52. package/docs/cartograph.md +2 -2
  53. package/docs/cartography.md +59 -3
  54. package/docs/testing.md +2 -1
  55. package/llms.txt +2 -2
  56. package/onlymapjs.attributes.json +1 -0
  57. package/onlymapjs.html-data.json +15 -1
  58. package/package.json +3 -2
  59. package/skills/onlymapjs/SKILL.md +2 -2
  60. package/skills/onlymapjs/references/syntax.md +7 -6
  61. package/dist/index-BHRpKnGi.js +0 -4883
@@ -1,22 +1,22 @@
1
- import { bz as Be, bA as le, bB as ce, bC as De, bD as Oe, bE as ke } from "./index-Bs69fn8a.js";
2
- import { y as ve, a as he, z as G, R as J, A as ue, C as Fe, F as je, n as xe, S as Ie, E as Ne } from "./recordbatch-Bpc0uxFn.js";
1
+ import { bF as Be, bG as le, bH as ce, bI as De, bJ as Oe, bK as ke } from "./index-CpFNIkOO.js";
2
+ import { y as Fe, a as he, z as G, R as J, A as ue, C as ve, F as je, n as xe, S as Ie, E as Ne } from "./recordbatch-Bpc0uxFn.js";
3
3
  import { g as V, a as fe, b as Le, c as Ue, d as Me, e as qe, m as Ve } from "./table-accessors-CYWTzpQI.js";
4
4
  import { c as $e } from "./convert-arrow-schema-DrAihRf9.js";
5
5
  function de(t) {
6
6
  switch (t.shape) {
7
7
  case "array-row-table":
8
8
  case "object-row-table":
9
- return He(t.data);
9
+ return Pe(t.data);
10
10
  case "geojson-table":
11
- return Pe(t.features);
11
+ return ze(t.features);
12
12
  case "columnar-table":
13
- return ze(t.data);
13
+ return He(t.data);
14
14
  case "arrow-table":
15
15
  default:
16
16
  throw new Error("Deduce schema");
17
17
  }
18
18
  }
19
- function ze(t) {
19
+ function He(t) {
20
20
  const e = [];
21
21
  for (const [r, s] of Object.entries(t)) {
22
22
  const n = Qe(s, r);
@@ -24,7 +24,7 @@ function ze(t) {
24
24
  }
25
25
  return { fields: e, metadata: {} };
26
26
  }
27
- function He(t) {
27
+ function Pe(t) {
28
28
  if (!t.length)
29
29
  throw new Error("deduce from empty table");
30
30
  const e = [], r = t[0];
@@ -32,7 +32,7 @@ function He(t) {
32
32
  e.push(me(n, s));
33
33
  return { fields: e, metadata: {} };
34
34
  }
35
- function Pe(t) {
35
+ function ze(t) {
36
36
  if (!t.length)
37
37
  throw new Error("deduce from empty table");
38
38
  const e = [], r = t[0].properties || {};
@@ -75,7 +75,7 @@ function Je(t, e) {
75
75
  return new r(e);
76
76
  }
77
77
  function* We(t, e) {
78
- const r = $e(t.schema), s = V(t), n = fe(t), a = s, c = r?.fields.map((o) => ve(o)), h = new he(r.fields);
78
+ const r = $e(t.schema), s = V(t), n = fe(t), a = s, c = r?.fields.map((o) => Fe(o)), h = new he(r.fields);
79
79
  let f = 0;
80
80
  for (let o = 0; o < s; o++)
81
81
  for (let u = 0; u < n; ++u) {
@@ -393,7 +393,7 @@ class at extends we {
393
393
  const e = super.getBatch();
394
394
  if (e) {
395
395
  this.arrowSchema = this.arrowSchema || ot(e.schema);
396
- const r = lt(this.arrowSchema, e.data), s = new J(this.arrowSchema, Fe({
396
+ const r = lt(this.arrowSchema, e.data), s = new J(this.arrowSchema, ve({
397
397
  type: new he(this.arrowSchema.fields),
398
398
  children: r.map(({ data: n }) => n[0])
399
399
  }));
@@ -578,7 +578,7 @@ class ut {
578
578
  });
579
579
  }
580
580
  }
581
- const re = "\uFEFF", F = {
581
+ const re = "\uFEFF", v = {
582
582
  RECORD_SEP: "",
583
583
  UNIT_SEP: "",
584
584
  BYTE_ORDER_MARK: re,
@@ -710,7 +710,7 @@ class be {
710
710
  j(this._config.delimiter) && (this._config.delimiter = this._config.delimiter(e), this._results.meta.delimiter = this._config.delimiter);
711
711
  else {
712
712
  const c = this.guessDelimiter(e, this._config.newline, this._config.skipEmptyLines, this._config.comments, this._config.delimitersToGuess);
713
- c.successful ? this._config.delimiter = c.bestDelimiter : (this._delimiterError = !0, this._config.delimiter = F.DefaultDelimiter), this._results.meta.delimiter = this._config.delimiter;
713
+ c.successful ? this._config.delimiter = c.bestDelimiter : (this._delimiterError = !0, this._config.delimiter = v.DefaultDelimiter), this._results.meta.delimiter = this._config.delimiter;
714
714
  }
715
715
  const a = _e(this._config);
716
716
  return this._config.preview && this._config.header && a.preview++, this._input = e, this._parser = new W(a), this._results = this._parser.parse(this._input, r, s), this.processResults(), this._paused ? { meta: { paused: !0 } } : this._results || { meta: { paused: !1 } };
@@ -734,7 +734,7 @@ class be {
734
734
  return this._config.skipEmptyLines === "greedy" ? e.join("").trim() === "" : e.length === 1 && e[0].length === 0;
735
735
  }
736
736
  processResults() {
737
- if (this._results && this._delimiterError && (this.addError("Delimiter", "UndetectableDelimiter", `Unable to auto-detect delimiting character; defaulted to '${F.DefaultDelimiter}'`), this._delimiterError = !1), this._config.skipEmptyLines)
737
+ if (this._results && this._delimiterError && (this.addError("Delimiter", "UndetectableDelimiter", `Unable to auto-detect delimiting character; defaulted to '${v.DefaultDelimiter}'`), this._delimiterError = !1), this._config.skipEmptyLines)
738
738
  for (let e = 0; e < this._results.data.length; e++)
739
739
  this.testEmptyLine(this._results.data[e]) && this._results.data.splice(e--, 1);
740
740
  return this.needsHeaderRow() && this.fillHeaderFields(), this.applyHeaderAndDynamicTypingAndTransformation();
@@ -779,7 +779,7 @@ class be {
779
779
  // eslint-disable-next-line complexity, max-statements
780
780
  guessDelimiter(e, r, s, n, a) {
781
781
  let c, h, f;
782
- a = a || [",", " ", "|", ";", F.RECORD_SEP, F.UNIT_SEP];
782
+ a = a || [",", " ", "|", ";", v.RECORD_SEP, v.UNIT_SEP];
783
783
  for (let o = 0; o < a.length; o++) {
784
784
  const u = a[o];
785
785
  let i = 0, d = 0, g = 0;
@@ -842,9 +842,9 @@ function W(t = {}) {
842
842
  let h;
843
843
  t.quoteChar === void 0 ? h = '"' : h = t.quoteChar;
844
844
  let f = h;
845
- if (t.escapeChar !== void 0 && (f = t.escapeChar), (typeof e != "string" || F.BAD_DELIMITERS.indexOf(e) > -1) && (e = ","), s === e)
845
+ if (t.escapeChar !== void 0 && (f = t.escapeChar), (typeof e != "string" || v.BAD_DELIMITERS.indexOf(e) > -1) && (e = ","), s === e)
846
846
  throw new Error("Comment character same as delimiter");
847
- s === !0 ? s = "#" : (typeof s != "string" || F.BAD_DELIMITERS.indexOf(s) > -1) && (s = !1), r !== `
847
+ s === !0 ? s = "#" : (typeof s != "string" || v.BAD_DELIMITERS.indexOf(s) > -1) && (s = !1), r !== `
848
848
  ` && r !== "\r" && r !== `\r
849
849
  ` && (r = `
850
850
  `);
@@ -854,7 +854,7 @@ function W(t = {}) {
854
854
  throw new Error("Input must be a string");
855
855
  const w = i.length, l = e.length, m = r.length, C = s.length, T = j(n);
856
856
  o = 0;
857
- let y = [], v = [], p = [], k = 0;
857
+ let y = [], F = [], p = [], k = 0;
858
858
  if (!i)
859
859
  return S();
860
860
  if (c || c !== !1 && i.indexOf(h) === -1) {
@@ -884,17 +884,17 @@ function W(t = {}) {
884
884
  if (i[o] === h) {
885
885
  for (b = o, o++; ; ) {
886
886
  if (b = i.indexOf(h, b + 1), b === -1)
887
- return g || v.push({
887
+ return g || F.push({
888
888
  type: "Quotes",
889
889
  code: "MissingQuotes",
890
890
  message: "Quoted field unterminated",
891
891
  row: y.length,
892
892
  // row has yet to be inserted
893
893
  index: o
894
- }), z();
894
+ }), H();
895
895
  if (b === w - 1) {
896
896
  const Ee = i.substring(o, b).replace(B, h);
897
- return z(Ee);
897
+ return H(Ee);
898
898
  }
899
899
  if (h === f && i[b + 1] === f) {
900
900
  b++;
@@ -918,7 +918,7 @@ function W(t = {}) {
918
918
  return S(!0);
919
919
  break;
920
920
  }
921
- v.push({
921
+ F.push({
922
922
  type: "Quotes",
923
923
  code: "InvalidQuotes",
924
924
  message: "Trailing quote on quoted field is malformed",
@@ -952,7 +952,7 @@ function W(t = {}) {
952
952
  }
953
953
  break;
954
954
  }
955
- return z();
955
+ return H();
956
956
  function x(R) {
957
957
  y.push(R), k = o;
958
958
  }
@@ -964,7 +964,7 @@ function W(t = {}) {
964
964
  }
965
965
  return D;
966
966
  }
967
- function z(R) {
967
+ function H(R) {
968
968
  return g || (typeof R > "u" && (R = i.substr(o)), p.push(R), o = w, x(p), T && I()), S();
969
969
  }
970
970
  function Y(R) {
@@ -973,7 +973,7 @@ function W(t = {}) {
973
973
  function S(R, D) {
974
974
  return {
975
975
  data: D || !1 ? y[0] : y,
976
- errors: v,
976
+ errors: F,
977
977
  meta: {
978
978
  delimiter: e,
979
979
  linebreak: r,
@@ -984,7 +984,7 @@ function W(t = {}) {
984
984
  };
985
985
  }
986
986
  function I() {
987
- n(S(void 0, !0)), y = [], v = [];
987
+ n(S(void 0, !0)), y = [], F = [];
988
988
  }
989
989
  }, this.abort = function() {
990
990
  u = !0;
@@ -1018,7 +1018,7 @@ function wt(t, e = {}) {
1018
1018
  throw new Error("Unable to serialize unrecognized input");
1019
1019
  function i() {
1020
1020
  if (typeof e == "object") {
1021
- if (typeof e.delimiter == "string" && !F.BAD_DELIMITERS.filter(function(l) {
1021
+ if (typeof e.delimiter == "string" && !v.BAD_DELIMITERS.filter(function(l) {
1022
1022
  return e.delimiter?.indexOf(l) !== -1;
1023
1023
  }).length && (n = e.delimiter), (typeof e.quotes == "boolean" || Array.isArray(e.quotes)) && (r = e.quotes), (typeof e.skipEmptyLines == "boolean" || e.skipEmptyLines === "greedy") && (f = e.skipEmptyLines), typeof e.newline == "string" && (a = e.newline), typeof e.quoteChar == "string" && (c = e.quoteChar), typeof e.header == "boolean" && (s = e.header), Array.isArray(e.columns)) {
1024
1024
  if (e.columns.length === 0)
@@ -1031,7 +1031,7 @@ function wt(t, e = {}) {
1031
1031
  function d(l, m, C) {
1032
1032
  let T = "";
1033
1033
  typeof l == "string" && (l = JSON.parse(l)), typeof m == "string" && (m = JSON.parse(m));
1034
- const y = Array.isArray(l) && l.length > 0, v = !Array.isArray(m[0]);
1034
+ const y = Array.isArray(l) && l.length > 0, F = !Array.isArray(m[0]);
1035
1035
  if (y && s) {
1036
1036
  for (let p = 0; p < l.length; p++)
1037
1037
  p > 0 && (T += n), T += g(l[p], p);
@@ -1044,7 +1044,7 @@ function wt(t, e = {}) {
1044
1044
  if (C && !y && (A = C === "greedy" ? m[p].join("").trim() === "" : m[p].length === 1 && m[p][0].length === 0), C === "greedy" && y) {
1045
1045
  const B = [];
1046
1046
  for (let b = 0; b < k; b++) {
1047
- const x = v ? l[b] : b;
1047
+ const x = F ? l[b] : b;
1048
1048
  B.push(m[p][x]);
1049
1049
  }
1050
1050
  A = B.join("").trim() === "";
@@ -1052,7 +1052,7 @@ function wt(t, e = {}) {
1052
1052
  if (!A) {
1053
1053
  for (let B = 0; B < k; B++) {
1054
1054
  B > 0 && !_ && (T += n);
1055
- const b = y && v ? l[B] : B;
1055
+ const b = y && F ? l[B] : B;
1056
1056
  T += g(m[p][b], B);
1057
1057
  }
1058
1058
  p < m.length - 1 && (!C || k > 0 && !_) && (T += a);
@@ -1061,7 +1061,7 @@ function wt(t, e = {}) {
1061
1061
  return T;
1062
1062
  }
1063
1063
  function g(l, m) {
1064
- return typeof l > "u" || l === null ? "" : l.constructor === Date ? JSON.stringify(l).slice(1, 25) : (l = l.toString().replace(u, h), typeof r == "boolean" && r || Array.isArray(r) && r[m] || w(l, F.BAD_DELIMITERS) || l.indexOf(n) > -1 || l.charAt(0) === " " || l.charAt(l.length - 1) === " " ? c + l + c : l);
1064
+ return typeof l > "u" || l === null ? "" : l.constructor === Date ? JSON.stringify(l).slice(1, 25) : (l = l.toString().replace(u, h), typeof r == "boolean" && r || Array.isArray(r) && r[m] || w(l, v.BAD_DELIMITERS) || l.indexOf(n) > -1 || l.charAt(0) === " " || l.charAt(l.length - 1) === " " ? c + l + c : l);
1065
1065
  }
1066
1066
  function w(l, m) {
1067
1067
  for (let C = 0; C < m.length; C++)
@@ -1074,7 +1074,7 @@ function yt(t) {
1074
1074
  return t.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
1075
1075
  }
1076
1076
  const $ = {
1077
- ...F,
1077
+ ...v,
1078
1078
  parse: ft,
1079
1079
  unparse: wt,
1080
1080
  ChunkStreamer: ye,
@@ -1294,7 +1294,7 @@ function Rt(t, e) {
1294
1294
  }
1295
1295
  };
1296
1296
  }
1297
- var ne = {}, H = {}, P = 34, N = 10, Q = 13;
1297
+ var ne = {}, P = {}, z = 34, N = 10, Q = 13;
1298
1298
  function Se(t) {
1299
1299
  return new Function("d", "return {" + t.map(function(e, r) {
1300
1300
  return JSON.stringify(e) + ": d[" + r + '] || ""';
@@ -1337,12 +1337,12 @@ function Dt(t) {
1337
1337
  function n(i, d) {
1338
1338
  var g = [], w = i.length, l = 0, m = 0, C, T = w <= 0, y = !1;
1339
1339
  i.charCodeAt(w - 1) === N && --w, i.charCodeAt(w - 1) === Q && --w;
1340
- function v() {
1341
- if (T) return H;
1340
+ function F() {
1341
+ if (T) return P;
1342
1342
  if (y) return y = !1, ne;
1343
1343
  var k, A = l, _;
1344
- if (i.charCodeAt(A) === P) {
1345
- for (; l++ < w && i.charCodeAt(l) !== P || i.charCodeAt(++l) === P; ) ;
1344
+ if (i.charCodeAt(A) === z) {
1345
+ for (; l++ < w && i.charCodeAt(l) !== z || i.charCodeAt(++l) === z; ) ;
1346
1346
  return (k = l) >= w ? T = !0 : (_ = i.charCodeAt(l++)) === N ? y = !0 : _ === Q && (y = !0, i.charCodeAt(l) === N && ++l), i.slice(A + 1, k - 1).replace(/""/g, '"');
1347
1347
  }
1348
1348
  for (; l < w; ) {
@@ -1354,8 +1354,8 @@ function Dt(t) {
1354
1354
  }
1355
1355
  return T = !0, i.slice(A, w);
1356
1356
  }
1357
- for (; (C = v()) !== H; ) {
1358
- for (var p = []; C !== ne && C !== H; ) p.push(C), C = v();
1357
+ for (; (C = F()) !== P; ) {
1358
+ for (var p = []; C !== ne && C !== P; ) p.push(C), C = F();
1359
1359
  d && (p = d(p, m++)) == null || g.push(p);
1360
1360
  }
1361
1361
  return g;
@@ -1405,14 +1405,14 @@ function ae(t, e = { csv: { useDisplayNames: !0 } }) {
1405
1405
  const f = [];
1406
1406
  for (let o = 0; o < fe(t); ++o) {
1407
1407
  const u = h[o];
1408
- f[o] = vt(u);
1408
+ f[o] = Ft(u);
1409
1409
  }
1410
1410
  a.push(f);
1411
1411
  }
1412
1412
  const c = a.map((h) => h.map((f) => f === null ? "" : f));
1413
1413
  return kt(c);
1414
1414
  }
1415
- const vt = (t) => t == null ? null : t instanceof Date ? t.toISOString() : typeof t == "object" ? JSON.stringify(t) : String(t), Ut = {
1415
+ const Ft = (t) => t == null ? null : t instanceof Date ? t.toISOString() : typeof t == "object" ? JSON.stringify(t) : String(t), Ut = {
1416
1416
  ...Ce,
1417
1417
  version: "latest",
1418
1418
  options: {
@@ -1429,13 +1429,13 @@ const vt = (t) => t == null ? null : t instanceof Date ? t.toISOString() : typeo
1429
1429
  batchType: null,
1430
1430
  parse: async (t, e) => oe(new TextDecoder().decode(t), e),
1431
1431
  parseText: (t, e) => oe(t, e),
1432
- parseInBatches: Ft
1432
+ parseInBatches: vt
1433
1433
  };
1434
1434
  async function oe(t, e) {
1435
1435
  const r = await U.parseText(t, e);
1436
1436
  return L(r, "arrow-table");
1437
1437
  }
1438
- function Ft(t, e) {
1438
+ function vt(t, e) {
1439
1439
  const r = U.parseInBatches(t, e);
1440
1440
  return rt(r, "arrow-table");
1441
1441
  }