@nika-js/onlymap 0.11.11 → 0.12.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 (58) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/README.md +9 -3
  3. package/dist/attribute-resolution.d.ts +2 -0
  4. package/dist/{basemap-QT4ua-dL.js → basemap-BK25o5OE.js} +1514 -1462
  5. package/dist/basemap.d.ts +41 -1
  6. package/dist/cartograph.js +362 -321
  7. package/dist/cartograph.standalone.js +1995 -1914
  8. package/dist/{cityjson-k-z1r6c0.js → cityjson-DMc_dwu1.js} +1 -1
  9. package/dist/{crs-BzE_KP4M.js → crs-D5FyQfEu.js} +74 -7
  10. package/dist/{crs-ChglCB3O.js → crs-ZdDBJ2EY.js} +39 -36
  11. package/dist/data-layer.d.ts +36 -3
  12. package/dist/elements/om-map.d.ts +2 -1
  13. package/dist/geoparquet-CLydPm2f.js +30 -0
  14. package/dist/geoparquet.d.ts +6 -7
  15. package/dist/{globe-view-BSGTUqWc.js → globe-view-ChuX60M5.js} +11 -11
  16. package/dist/hillshade-DD8WFrvf.js +209 -0
  17. package/dist/html-data.d.ts +1 -1
  18. package/dist/{ifc-DXwePQRv.js → ifc-sisRo7I7.js} +1 -1
  19. package/dist/{index-DudIuhJa.js → index-BHRpKnGi.js} +1 -1
  20. package/dist/{index-CevWTqBO.js → index-Bs69fn8a.js} +14362 -13782
  21. package/dist/{index-DBt_2x-w.js → index-C2CKUsom.js} +106 -106
  22. package/dist/{index-DjYxw-8H.js → index-CMKrghNb.js} +18 -18
  23. package/dist/{index-Dwc4s3mc.js → index-CdAf0bLj.js} +20 -20
  24. package/dist/{index-BO7MtTkn.js → index-CgVFHEdM.js} +3 -3
  25. package/dist/{index-Bxue4Psc.js → index-CvrH6mbS.js} +9 -9
  26. package/dist/{index-Bzypgr1v.js → index-DIzzRLKr.js} +1 -1
  27. package/dist/{index-D1ZjhP2H.js → index-Dvwr1Y3o.js} +11 -11
  28. package/dist/index.d.ts +3 -2
  29. package/dist/ir.d.ts +6 -0
  30. package/dist/layer-registry.d.ts +21 -0
  31. package/dist/layers/warped-bitmap-layer.d.ts +27 -0
  32. package/dist/{lerc-DQuf93SN.js → lerc-mAijS40k.js} +1 -1
  33. package/dist/onlymap.standalone.js +53019 -52455
  34. package/dist/onlymapjs.js +86 -84
  35. package/dist/parse-manifest.d.ts +12 -9
  36. package/dist/{post-process-effect-B3j_nBzy.js → post-process-effect-rwFDi8di.js} +5 -5
  37. package/dist/programmatic.d.ts +12 -0
  38. package/dist/projection.d.ts +44 -1
  39. package/dist/{raster-CvAJ-h_g.js → raster-CXIqf83L.js} +3 -3
  40. package/dist/{raster-pipeline-CusoihQ3.js → raster-pipeline-CfSg2Re7.js} +1 -1
  41. package/dist/react/om-layer.d.ts +4 -0
  42. package/dist/react/om-map.d.ts +2 -0
  43. package/dist/react.js +225 -218
  44. package/dist/runtime-core.d.ts +24 -0
  45. package/dist/source-crs.d.ts +99 -0
  46. package/dist/{text-on-path-D9u5SYCo.js → text-on-path-B08PekFz.js} +1 -1
  47. package/dist/version.d.ts +1 -1
  48. package/dist/{zarr-DWb_nikR.js → zarr-CUn2udOc.js} +2 -2
  49. package/docs/cartograph.md +2 -2
  50. package/docs/cartography.md +106 -1
  51. package/llms.txt +2 -1
  52. package/onlymapjs.attributes.json +2 -0
  53. package/onlymapjs.html-data.json +26 -4
  54. package/package.json +1 -1
  55. package/skills/onlymapjs/SKILL.md +5 -3
  56. package/skills/onlymapjs/references/syntax.md +18 -3
  57. package/dist/geoparquet-hOsdfZJa.js +0 -35
  58. package/dist/hillshade-D2Ps3Nim.js +0 -298
@@ -1,5 +1,5 @@
1
- import { aM as R, aN as S, aO as E, aP as N, aQ as h, aR as w, aS as W, aT as O, aU as x, aV as I, aW as B, aX as _, aY as P, aZ as k, a_ as $, a$ as z, b0 as C, b1 as F, b2 as v, b3 as M, b4 as p, b5 as U } from "./index-CevWTqBO.js";
2
- import { b6 as $e, b7 as ze, b8 as Ce, b9 as ve, ba as Me, bb as Ue, bc as je, bd as De, be as qe, bf as Je, bg as Ve, bh as Ge, bi as He, bj as Qe, bk as Xe, bl as Ye, bm as Ze, bn as Ke, bo as et, bp as tt, bq as nt, br as rt, bs as at, bt as st, bu as ot } from "./index-CevWTqBO.js";
1
+ import { aO as R, aP as S, aQ as E, aR as W, aS as h, aT as w, aU as N, aV as O, aW as x, aX as I, aY as B, aZ as _, a_ as P, a$ as k, b0 as $, b1 as z, b2 as v, b3 as F, b4 as C, b5 as U, b6 as p, b7 as M } from "./index-Bs69fn8a.js";
2
+ import { b8 as $e, b9 as ze, ba as ve, bb as Ce, bc as Ue, bd as Me, be as je, bf as De, bg as qe, bh as Je, bi as Ve, bj as Ge, bk as He, bl as Qe, bm as Xe, bn as Ye, bo as Ze, bp as Ke, bq as et, br as tt, bs as nt, bt as rt, bu as at, bv as st, bw as ot } from "./index-Bs69fn8a.js";
3
3
  import { g as j, i as D } from "./table-accessors-CYWTzpQI.js";
4
4
  async function q(t, e, n = {}, r = {}) {
5
5
  const a = R(t), s = S.getWorkerFarm(n), { source: o } = n, c = { name: a, source: o };
@@ -8,7 +8,7 @@ async function q(t, e, n = {}, r = {}) {
8
8
  u,
9
9
  // eslint-disable-next-line
10
10
  J.bind(null, r)
11
- ), y = N(n);
11
+ ), y = W(n);
12
12
  return d.postMessage("process", { input: e, options: y }), (await d.result).result;
13
13
  }
14
14
  async function J(t, e, n, r) {
@@ -158,7 +158,7 @@ async function X(t) {
158
158
  }
159
159
  function Se(t, e, n, r) {
160
160
  !Array.isArray(e) && !w(e) && (r = void 0, n = e, e = void 0), n = n || {};
161
- const s = W(e, r), o = O(t, s, n);
161
+ const s = N(e, r), o = O(t, s, n);
162
162
  if (!o)
163
163
  return null;
164
164
  const c = x(n, o, s), i = I(t), u = () => {
@@ -237,7 +237,7 @@ async function re(t, e = []) {
237
237
  function xe(t, e, n, r) {
238
238
  let a;
239
239
  !Array.isArray(e) && !w(e) ? (n = e, a = void 0) : a = e;
240
- const s = C(n || {});
240
+ const s = v(n || {});
241
241
  return Array.isArray(t) ? t.map((c) => g(c, a, n || {}, s)) : g(t, a, n || {}, s);
242
242
  }
243
243
  async function g(t, e, n, r) {
@@ -258,7 +258,7 @@ async function ae(t, e, n) {
258
258
  const r = se(t, e, n), a = [];
259
259
  for await (const s of r)
260
260
  a.push(s);
261
- return v(...a);
261
+ return C(...a);
262
262
  }
263
263
  throw new Error("Writer could not encode data");
264
264
  }
@@ -282,7 +282,7 @@ function oe(t) {
282
282
  return [{ ...t, start: 0, end: t.length }];
283
283
  }
284
284
  async function Be(t, e, n) {
285
- const a = { ...M(), ...n };
285
+ const a = { ...U(), ...n };
286
286
  return e.encodeURLtoURL ? ue(e, t, a) : V(e, a) ? await q(e, t, a) : await e.encode(t, a);
287
287
  }
288
288
  function ce(t, e, n) {
@@ -330,7 +330,7 @@ async function ue(t, e, n) {
330
330
  const r = T("input");
331
331
  await new Q(r, "w").write(e);
332
332
  const s = T("output"), o = await ie(r, s, t, n);
333
- return (await U(o)).arrayBuffer();
333
+ return (await M(o)).arrayBuffer();
334
334
  }
335
335
  function fe(t) {
336
336
  return [{ ...t, start: 0, end: t.length }];
@@ -402,7 +402,7 @@ const L = "4.4.3", Ee = {
402
402
  options: {
403
403
  null: {}
404
404
  }
405
- }, Ne = {
405
+ }, We = {
406
406
  dataType: null,
407
407
  batchType: null,
408
408
  name: "Null loader",
@@ -425,7 +425,7 @@ const L = "4.4.3", Ee = {
425
425
  function m(t, e, n) {
426
426
  return null;
427
427
  }
428
- async function We(t, e, n = () => {
428
+ async function Ne(t, e, n = () => {
429
429
  }, r = () => {
430
430
  }) {
431
431
  if (t = await t, !t.ok)
@@ -536,17 +536,17 @@ class Oe {
536
536
  export {
537
537
  $e as FetchError,
538
538
  ge as JSONLoader,
539
- Ne as NullLoader,
539
+ We as NullLoader,
540
540
  Ee as NullWorkerLoader,
541
541
  ze as RequestScheduler,
542
542
  Oe as _BrowserFileSystem,
543
- We as _fetchProgress,
543
+ Ne as _fetchProgress,
544
544
  Ae as _selectSource,
545
- Ce as _unregisterLoaders,
546
- ve as assert,
545
+ ve as _unregisterLoaders,
546
+ Ce as assert,
547
547
  z as concatenateArrayBuffersAsync,
548
- Me as createDataSource,
549
- Ue as document,
548
+ Ue as createDataSource,
549
+ Me as document,
550
550
  Be as encode,
551
551
  Le as encodeInBatches,
552
552
  ce as encodeSync,
@@ -556,9 +556,9 @@ export {
556
556
  ke as encodeText,
557
557
  Fe as encodeTextSync,
558
558
  ie as encodeURLtoURL,
559
- U as fetchFile,
559
+ M as fetchFile,
560
560
  je as forEach,
561
- M as getLoaderOptions,
561
+ U as getLoaderOptions,
562
562
  De as getPathPrefix,
563
563
  qe as global,
564
564
  Je as isAsyncIterable,
@@ -1,5 +1,5 @@
1
- import { bx as Be, by as le, bz as ce, bA as De, bB as Oe, bC as ke } from "./index-CevWTqBO.js";
2
- import { y as ve, a as he, z as G, R as J, A as ue, C as Fe, F as xe, n as je, S as Ie, E as Ne } from "./recordbatch-Bpc0uxFn.js";
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";
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) {
@@ -412,7 +412,7 @@ function ot(t) {
412
412
  for (const r in t) {
413
413
  const s = t[r];
414
414
  if (s.type === Float32Array) {
415
- const n = /* @__PURE__ */ new Map(), a = new xe(s.name, new je(), s.nullable, n);
415
+ const n = /* @__PURE__ */ new Map(), a = new je(s.name, new xe(), s.nullable, n);
416
416
  e.push(a);
417
417
  }
418
418
  }
@@ -620,7 +620,7 @@ let ye = class {
620
620
  }
621
621
  // eslint-disable-next-line complexity, max-statements
622
622
  parseChunk(e, r) {
623
- if (this.isFirstChunk && x(this._config.beforeFirstChunk)) {
623
+ if (this.isFirstChunk && j(this._config.beforeFirstChunk)) {
624
624
  const h = this._config.beforeFirstChunk(e);
625
625
  h !== void 0 && (e = h);
626
626
  }
@@ -633,15 +633,15 @@ let ye = class {
633
633
  const a = n.meta.cursor;
634
634
  this._finished || (this._partialLine = s.substring(a - this._baseIndex), this._baseIndex = a), n && n.data && (this._rowCount += n.data.length);
635
635
  const c = this._finished || this._config.preview && this._rowCount >= this._config.preview;
636
- if (x(this._config.chunk) && !r) {
636
+ if (j(this._config.chunk) && !r) {
637
637
  if (this._config.chunk(n, this._handle), this._handle.paused() || this._handle.aborted())
638
638
  return;
639
639
  n = void 0, this._completeResults = void 0;
640
640
  }
641
- return !this._config.step && !this._config.chunk && (this._completeResults.data = this._completeResults.data.concat(n.data), this._completeResults.errors = this._completeResults.errors.concat(n.errors), this._completeResults.meta = n.meta), !this._completed && c && x(this._config.complete) && (!n || !n.meta.aborted) && (this._config.complete(this._completeResults, this._input), this._completed = !0), n;
641
+ return !this._config.step && !this._config.chunk && (this._completeResults.data = this._completeResults.data.concat(n.data), this._completeResults.errors = this._completeResults.errors.concat(n.errors), this._completeResults.meta = n.meta), !this._completed && c && j(this._config.complete) && (!n || !n.meta.aborted) && (this._config.complete(this._completeResults, this._input), this._completed = !0), n;
642
642
  }
643
643
  _sendError(e) {
644
- x(this._config.error) && this._config.error(e);
644
+ j(this._config.error) && this._config.error(e);
645
645
  }
646
646
  };
647
647
  class dt extends ye {
@@ -685,7 +685,7 @@ class be {
685
685
  meta: {}
686
686
  };
687
687
  constructor(e) {
688
- if (x(e.step)) {
688
+ if (j(e.step)) {
689
689
  const r = e.step;
690
690
  e.step = (s) => {
691
691
  if (this._results = s, this.needsHeaderRow())
@@ -707,7 +707,7 @@ class be {
707
707
  parse(e, r, s) {
708
708
  const n = this._config.quoteChar || '"';
709
709
  if (this._config.newline || (this._config.newline = gt(e, n)), this._delimiterError = !1, this._config.delimiter)
710
- x(this._config.delimiter) && (this._config.delimiter = this._config.delimiter(e), this._results.meta.delimiter = this._config.delimiter);
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
713
  c.successful ? this._config.delimiter = c.bestDelimiter : (this._delimiterError = !0, this._config.delimiter = F.DefaultDelimiter), this._results.meta.delimiter = this._config.delimiter;
@@ -728,7 +728,7 @@ class be {
728
728
  return this._aborted;
729
729
  }
730
730
  abort() {
731
- this._aborted = !0, this._parser.abort(), this._results.meta.aborted = !0, x(this._config.complete) && this._config.complete(this._results), this._input = "";
731
+ this._aborted = !0, this._parser.abort(), this._results.meta.aborted = !0, j(this._config.complete) && this._config.complete(this._results), this._input = "";
732
732
  }
733
733
  testEmptyLine(e) {
734
734
  return this._config.skipEmptyLines === "greedy" ? e.join("").trim() === "" : e.length === 1 && e[0].length === 0;
@@ -746,7 +746,7 @@ class be {
746
746
  if (!this._results)
747
747
  return;
748
748
  const e = (r) => {
749
- x(this._config.transformHeader) && (r = this._config.transformHeader(r)), this._fields.push(r);
749
+ j(this._config.transformHeader) && (r = this._config.transformHeader(r)), this._fields.push(r);
750
750
  };
751
751
  if (Array.isArray(this._results.data[0])) {
752
752
  for (let r = 0; this.needsHeaderRow() && r < this._results.data.length; r++)
@@ -852,7 +852,7 @@ function W(t = {}) {
852
852
  this.parse = function(i, d, g) {
853
853
  if (typeof i != "string")
854
854
  throw new Error("Input must be a string");
855
- const w = i.length, l = e.length, m = r.length, C = s.length, T = x(n);
855
+ const w = i.length, l = e.length, m = r.length, C = s.length, T = j(n);
856
856
  o = 0;
857
857
  let y = [], v = [], p = [], k = 0;
858
858
  if (!i)
@@ -867,10 +867,10 @@ function W(t = {}) {
867
867
  return S();
868
868
  if (!(s && O.substr(0, C) === s)) {
869
869
  if (T) {
870
- if (y = [], j(O.split(e)), I(), u)
870
+ if (y = [], x(O.split(e)), I(), u)
871
871
  return S();
872
872
  } else
873
- j(O.split(e));
873
+ x(O.split(e));
874
874
  if (a && D >= a)
875
875
  return y = y.slice(0, a), S(!0);
876
876
  }
@@ -953,7 +953,7 @@ function W(t = {}) {
953
953
  break;
954
954
  }
955
955
  return z();
956
- function j(R) {
956
+ function x(R) {
957
957
  y.push(R), k = o;
958
958
  }
959
959
  function K(R) {
@@ -965,10 +965,10 @@ function W(t = {}) {
965
965
  return D;
966
966
  }
967
967
  function z(R) {
968
- return g || (typeof R > "u" && (R = i.substr(o)), p.push(R), o = w, j(p), T && I()), S();
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) {
971
- o = R, j(p), p = [], _ = i.indexOf(r, o);
971
+ o = R, x(p), p = [], _ = i.indexOf(r, o);
972
972
  }
973
973
  function S(R, D) {
974
974
  return {
@@ -1000,7 +1000,7 @@ function _e(t) {
1000
1000
  e[r] = _e(t[r]);
1001
1001
  return e;
1002
1002
  }
1003
- function x(t) {
1003
+ function j(t) {
1004
1004
  return typeof t == "function";
1005
1005
  }
1006
1006
  function wt(t, e = {}) {
@@ -1044,8 +1044,8 @@ 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 j = v ? l[b] : b;
1048
- B.push(m[p][j]);
1047
+ const x = v ? l[b] : b;
1048
+ B.push(m[p][x]);
1049
1049
  }
1050
1050
  A = B.join("").trim() === "";
1051
1051
  }
@@ -1,6 +1,6 @@
1
- import { A as t, a as o, b as i, C as l, c as p, d as n, D as _, e as c, f as g, F as h, L as m, g as L, h as y, i as f, j as w, M as S, k as V, O as b, l as C, m as E, P as I, T as P, n as T, o as M, U as d, V as A, p as O, q as u, W as N, r as k, s as x, t as D, u as G, G as R, v as j, w as W, x as q, y as v, z, B as F, E as U, H as Y, I as B, J as H, K as J, N as K, Q, R as X, S as Z, X as $, Y as aa, Z as sa, _ as ea, $ as ra, a0 as ta, a1 as oa, a2 as ia } from "./index-CevWTqBO.js";
2
- import { P as s } from "./post-process-effect-B3j_nBzy.js";
3
- import { G as pa, a as na } from "./globe-view-BSGTUqWc.js";
1
+ import { A as t, a as o, b as i, C as l, c as p, d as n, D as _, e as c, f as g, F as h, L as m, g as L, h as y, i as f, j as w, M as S, k as V, O as b, l as C, m as E, P as I, T as P, n as T, o as M, U as d, V as A, p as O, q as u, W as N, r as k, s as x, t as D, u as G, G as R, v as j, w as W, x as q, y as v, z, B as F, E as U, H as Y, I as B, J as H, K as J, N as K, Q, R as X, S as Z, X as $, Y as aa, Z as sa, _ as ea, $ as ra, a0 as ta, a1 as oa, a2 as ia } from "./index-Bs69fn8a.js";
2
+ import { P as s } from "./post-process-effect-rwFDi8di.js";
3
+ import { G as pa, a as na } from "./globe-view-ChuX60M5.js";
4
4
  export {
5
5
  t as AmbientLight,
6
6
  o as Attribute,
@@ -1,6 +1,6 @@
1
- import { ac as j, ad as S, ae as A, af as M, ag as L } from "./index-CevWTqBO.js";
2
- import { ah as H, ai as V, aj as X, ak as K } from "./index-CevWTqBO.js";
3
- import { P as h } from "./post-process-effect-B3j_nBzy.js";
1
+ import { an as j, ao as S, ap as A, aq as M, ar as L } from "./index-Bs69fn8a.js";
2
+ import { as as H, at as V, au as X, av as K } from "./index-Bs69fn8a.js";
3
+ import { P as h } from "./post-process-effect-rwFDi8di.js";
4
4
  const O = `
5
5
  float omfx_lum(vec3 c) { return dot(c, vec3(0.299, 0.587, 0.114)); }
6
6
  float omfx_hash(vec2 p) { return fract(sin(dot(p, vec2(12.9898, 78.233))) * 43758.5453); }
@@ -146,12 +146,12 @@ function T(o, e) {
146
146
  const i = `${e}.pxPerMm`, f = (a) => (u) => n.get(`${a}:${u}`) ?? "0.0", m = [], d = [];
147
147
  z(o).forEach((a, u) => {
148
148
  if (a.kind === "pointwise") {
149
- const p = `${e}_p${u}`, E = a.ops.map(($) => o[$].def.glsl(f($), i)).join(`
149
+ const p = `${e}_p${u}`, k = a.ops.map(($) => o[$].def.glsl(f($), i)).join(`
150
150
  `);
151
151
  m.push(
152
152
  `vec4 ${p}(vec4 inColor, vec2 texSize, vec2 coord) {
153
153
  ${y}
154
- ${E}
154
+ ${k}
155
155
  ${_}
156
156
  }`
157
157
  ), d.push({ filter: p });
@@ -186,7 +186,7 @@ ${_}
186
186
  };
187
187
  }
188
188
  const C = /^\s*(-?[\d.]+)\s*(mm)?\s*$/i, N = /^\s*(-?[\d.]+)\s*(deg)?\s*$/i;
189
- function k(o, e) {
189
+ function E(o, e) {
190
190
  if (o.kind === "color") {
191
191
  const s = L(e);
192
192
  if (!s) return;
@@ -203,14 +203,14 @@ function k(o, e) {
203
203
  return Number.isFinite(t) ? t : void 0;
204
204
  }
205
205
  function U(o) {
206
- return k(o, String(o.default)) ?? 0;
206
+ return E(o, String(o.default)) ?? 0;
207
207
  }
208
208
  function P(o, e) {
209
209
  const t = b(o);
210
210
  if (!t) return null;
211
211
  const s = {};
212
212
  for (const n of t.params) {
213
- const l = e(n.name), c = l === null ? void 0 : k(n, l);
213
+ const l = e(n.name), c = l === null ? void 0 : E(n, l);
214
214
  s[n.name] = c ?? U(n);
215
215
  }
216
216
  return { op: o, values: s };
@@ -313,7 +313,7 @@ export {
313
313
  V as OP_META,
314
314
  X as OP_NAMES,
315
315
  D as buildPostProcessEffects,
316
- k as coerceParam,
316
+ E as coerceParam,
317
317
  K as expandPreset,
318
318
  A as isEffectPreset,
319
319
  b as opDef,
@@ -1,4 +1,4 @@
1
- import { aA as B } from "./index-CevWTqBO.js";
1
+ import { aB as B } from "./index-Bs69fn8a.js";
2
2
  const V = /* @__PURE__ */ new Set([
3
3
  "GeoJsonLayer",
4
4
  "PolygonLayer",
@@ -1,4 +1,4 @@
1
- import { aB as tt, aC as et, aD as j, at as nt, au as ot, aE as B, aF as rt, aG as U, aq as st, ar as _, aH as C, aI as it } from "./index-CevWTqBO.js";
1
+ import { aC as tt, aD as et, aE as q, ab as nt, ac as ot, aF as C, aG as rt, aH as U, a7 as st, a8 as _, aI as L, aJ as it } from "./index-Bs69fn8a.js";
2
2
  const J = Math.PI / 180, T = tt * J;
3
3
  function Q(t, r) {
4
4
  const n = Math.max(Math.cos(r * J), 1e-6);
@@ -118,8 +118,8 @@ function mt(t) {
118
118
  return n(t), r;
119
119
  }
120
120
  function dt(t, r, n) {
121
- if (!j(t[0], r, n)) return !1;
122
- for (let o = 1; o < t.length; o++) if (j(t[o], r, n)) return !1;
121
+ if (!q(t[0], r, n)) return !1;
122
+ for (let o = 1; o < t.length; o++) if (q(t[o], r, n)) return !1;
123
123
  return !0;
124
124
  }
125
125
  function pt(t, r, n) {
@@ -191,7 +191,7 @@ function gt(t, r) {
191
191
  }
192
192
  return n;
193
193
  }
194
- function L(t, r, n, o, a) {
194
+ function B(t, r, n, o, a) {
195
195
  let s = 0;
196
196
  o[0] = 0, a[0] = -$, a[1] = $;
197
197
  for (let e = 1; e < r; e++) {
@@ -213,13 +213,13 @@ function W(t, r, n) {
213
213
  const a = Math.max(r, n), s = new Float64Array(a), e = new Float64Array(a), f = new Int32Array(a), c = new Float64Array(a + 1);
214
214
  for (let i = 0; i < r; i++) {
215
215
  for (let u = 0; u < n; u++) s[u] = o[u * r + i];
216
- L(s, n, e, f, c);
216
+ B(s, n, e, f, c);
217
217
  for (let u = 0; u < n; u++) o[u * r + i] = e[u];
218
218
  }
219
219
  for (let i = 0; i < n; i++) {
220
220
  const u = i * r;
221
221
  for (let l = 0; l < r; l++) s[l] = o[u + l];
222
- L(s, r, e, f, c);
222
+ B(s, r, e, f, c);
223
223
  for (let l = 0; l < r; l++) o[u + l] = Math.sqrt(e[l]);
224
224
  }
225
225
  return o;
@@ -411,7 +411,7 @@ function It(t) {
411
411
  return Math.atan(Math.sinh(Math.PI * (1 - 2 * t))) * 180 / Math.PI;
412
412
  }
413
413
  async function Pt(t) {
414
- const [r, n, o, a] = t.bounds, s = Math.max(0, Math.round(t.zoom)), e = B(r, a, s), f = B(o, n, s), c = Math.min(e.x, f.x), i = Math.max(e.x, f.x), u = Math.min(e.y, f.y), l = Math.max(e.y, f.y), y = (i - c + 1) * (l - u + 1);
414
+ const [r, n, o, a] = t.bounds, s = Math.max(0, Math.round(t.zoom)), e = C(r, a, s), f = C(o, n, s), c = Math.min(e.x, f.x), i = Math.max(e.x, f.x), u = Math.min(e.y, f.y), l = Math.max(e.y, f.y), y = (i - c + 1) * (l - u + 1);
415
415
  if (y <= 0 || y > t.maxTiles) return null;
416
416
  const h = (i - c + 1) * I, m = (l - u + 1) * I, d = new Float32Array(h * m), p = new Uint8Array(h * m), M = await Promise.all(
417
417
  Array.from({ length: y }, (k, g) => {
@@ -425,8 +425,8 @@ async function Pt(t) {
425
425
  const A = (k - c) * I, x = (g - u) * I, P = Math.min(I, b.height), R = Math.min(I, b.width);
426
426
  for (let E = 0; E < P; E++)
427
427
  for (let v = 0; v < R; v++) {
428
- const X = (E * b.width + v) * 4, q = (x + E) * h + A + v;
429
- d[q] = ot(t.decoder, b.data[X], b.data[X + 1], b.data[X + 2]), p[q] = 1;
428
+ const X = (E * b.width + v) * 4, j = (x + E) * h + A + v;
429
+ d[j] = ot(t.decoder, b.data[X], b.data[X + 1], b.data[X + 2]), p[j] = 1;
430
430
  }
431
431
  }
432
432
  const F = { width: h, height: m, cell: 1, originX: 0, originY: 0 }, w = 2 ** s;
@@ -493,7 +493,7 @@ async function Gt(t, r, n, o, a) {
493
493
  S(a, '<om-transform type="simplify"> needs a tolerance with a unit.', 'Write tolerance="0.15mm" (paper) or tolerance="50m" (ground).');
494
494
  break;
495
495
  }
496
- const c = C(f, o);
496
+ const c = L(f, o);
497
497
  if (c == null) {
498
498
  S(a, '<om-transform type="simplify"> has a tolerance in millimetres but this map declares no reference scale.', 'Add reference-scale="1:50000" to <om-map>, or author the tolerance in ground units (tolerance="50m").');
499
499
  break;
@@ -545,7 +545,7 @@ async function Gt(t, r, n, o, a) {
545
545
  S(a, '<om-transform type="buffer"> needs a distance with a unit.', 'Write distance="1.2mm" (paper) or distance="500m" (ground).');
546
546
  break;
547
547
  }
548
- const c = C(f, o);
548
+ const c = L(f, o);
549
549
  if (c == null) {
550
550
  S(a, '<om-transform type="buffer"> has a distance in millimetres but this map declares no reference scale.', 'Add reference-scale="1:50000" to <om-map>, or author the distance in ground units (distance="500m").');
551
551
  break;
package/dist/index.d.ts CHANGED
@@ -32,7 +32,7 @@ import { registerWidget } from "./widget-registry";
32
32
  import { registerAction } from "./actions";
33
33
  import { registerBasemap, configureBasemap } from "./basemap-registry";
34
34
  import { registerTerrain } from "./terrain";
35
- import { registerCrs } from "./projection";
35
+ import { registerCrs, configureCrs } from "./projection";
36
36
  import { registerRoutingProvider } from "./providers";
37
37
  import { configureTelemetry } from "./telemetry";
38
38
  import { configureLicense, setKeepBadge, badgeMode } from "./license";
@@ -60,7 +60,7 @@ export type { BasemapPreset, BasemapStyle } from "./basemap-registry";
60
60
  export { LIGHTING_PRESET_NAMES, resolveLighting, solarAzElDegrees } from "./scene-lighting";
61
61
  export type { LightingIR, LightingOptions, LightingPresetName } from "./scene-lighting";
62
62
  export { registerTerrain, getTerrain, parseTerrainAttrs } from "./terrain";
63
- export { registerCrs, resolveProjection, registeredCrsCodes } from "./projection";
63
+ export { registerCrs, resolveProjection, registeredCrsCodes, configureCrs, resolveCrs, type CrsConfig } from "./projection";
64
64
  export type { Projection, PlaneUnits, LngLatPair, PlaneXY } from "./projection";
65
65
  export type { TerrainPreset, TerrainIR, ElevationDecoder, LayerTerrainMode } from "./terrain";
66
66
  export { registerRoutingProvider, getRoutingProvider, lineStringLengthMeters } from "./providers";
@@ -136,6 +136,7 @@ export declare const OmMap: {
136
136
  registerBasemap: typeof registerBasemap;
137
137
  registerTerrain: typeof registerTerrain;
138
138
  registerCrs: typeof registerCrs;
139
+ configureCrs: typeof configureCrs;
139
140
  registerRoutingProvider: typeof registerRoutingProvider;
140
141
  configureBasemap: typeof configureBasemap;
141
142
  configureData: typeof configureData;
package/dist/ir.d.ts CHANGED
@@ -153,4 +153,10 @@ export interface LayerIR {
153
153
  * host class when this is set.
154
154
  */
155
155
  cluster?: ClusterOptions;
156
+ /**
157
+ * The layer's source CRS is still resolving (docs/design/crs.md): its data is
158
+ * the empty placeholder until proj4 loads or epsg.io answers, and readiness
159
+ * waits on it the way it waits on a pending data URL.
160
+ */
161
+ crsPending?: boolean;
156
162
  }
@@ -119,6 +119,27 @@ export interface LayerSchema {
119
119
  export declare const MERCATOR_PYRAMID_TYPES: readonly string[];
120
120
  /** Whether this type draws Mercator-pyramid tiles and has NOT been taught the plane. */
121
121
  export declare function needsMercatorPyramid(type: string): boolean;
122
+ /**
123
+ * Layer types that cannot draw on a globe (docs/design/globe.md), each with
124
+ * the reason the validation error gives. Measured 2026-10-08 on the basemap
125
+ * globe (MapLibre's sphere, deck's GlobeView over it):
126
+ *
127
+ * - Screen-space aggregation has no globe path in deck: HeatmapLayer drew
128
+ * nothing and logged a shader binding error; HexagonLayer collapsed to a
129
+ * speck. Grid, ScreenGrid and Contour share the machinery.
130
+ * - TerrainLayer is unsupported by deck's GlobeView.
131
+ * - ArcLayer (and GreatCircleLayer, built on it) drew a speck and stray
132
+ * fragments in space, with or without `great-circle`. PathLayer draws on the
133
+ * surface and is the route to suggest.
134
+ * - Text and icon quads are wound the other way round from the surface, and
135
+ * GlobeView culls back faces to hide the far side of the planet — so every
136
+ * glyph and icon is culled. Turning culling off draws them, far side and
137
+ * all, through the planet. Until labels learn the globe, these refuse.
138
+ *
139
+ * Listed here, not in the validator, so "what draws on a globe" has one home,
140
+ * as MERCATOR_PYRAMID_TYPES does for projected maps.
141
+ */
142
+ export declare const NOT_ON_GLOBE: Readonly<Record<string, string>>;
122
143
  export declare function registerLayer(schema: Omit<LayerSchema, "tier"> & {
123
144
  tier?: LayerSchema["tier"];
124
145
  }): void;
@@ -0,0 +1,27 @@
1
+ /**
2
+ * An image tile drawn on a projected map (docs/design/crs.md, gap 2).
3
+ *
4
+ * `BitmapLayer` builds its mesh from `bounds`, interpolating linearly between
5
+ * four corners — exactly a Mercator rectangle, and exactly wrong in any other
6
+ * projection, where a Web Mercator tile is a curved quadrilateral. Overriding
7
+ * `_createMesh` is the whole warp: the tile is subdivided and each vertex is
8
+ * projected on the CPU through `projection.ts`, and the GPU interpolates the
9
+ * texture across each warped quad. The technique, the subdivision rule and its
10
+ * measured error are the relief layer's (`plane-warp.ts`, carto-substrate §9);
11
+ * this is that warp without the shading.
12
+ */
13
+ import { BitmapLayer } from "@deck.gl/layers";
14
+ import { type TileBoundsLngLat } from "../plane-warp";
15
+ import type { PlaneFrame } from "../projection";
16
+ export interface WarpedBitmapProps {
17
+ /** The map's projection plane. Absent → a plain BitmapLayer. */
18
+ _planeFrame?: PlaneFrame | null;
19
+ /** The tile's geographic extent — what the mesh projects. */
20
+ _planeBounds?: TileBoundsLngLat;
21
+ /** Cells per axis (`subdivisionFor`). */
22
+ _subdivision?: number;
23
+ }
24
+ export declare class WarpedBitmapLayer extends BitmapLayer<WarpedBitmapProps> {
25
+ static layerName: string;
26
+ protected _createMesh(): import("../plane-warp").WarpMesh;
27
+ }
@@ -1,4 +1,4 @@
1
- import { C as o, D as s } from "./raster-CvAJ-h_g.js";
1
+ import { C as o, D as s } from "./raster-CXIqf83L.js";
2
2
  var t;
3
3
  (function(e) {
4
4
  e[e.None = 0] = "None", e[e.Deflate = 1] = "Deflate", e[e.Zstd = 2] = "Zstd";