@nika-js/onlymap 0.13.1 → 0.13.3
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/CHANGELOG.md +32 -0
- package/README.md +3 -2
- package/bin/dem-tiles.mjs +270 -0
- package/bin/onlymapjs.mjs +138 -34
- package/dist/{basemap-zG1-omic.js → basemap-5NHR6Gio.js} +2 -2
- package/dist/{build-Bbi4SleC.js → build-DJjheWZ2.js} +10 -10
- package/dist/camera-altitude.d.ts +29 -0
- package/dist/{client-CIH6ToMI.js → client-0mQmDog8.js} +2 -2
- package/dist/color.d.ts +15 -0
- package/dist/credit-chrome.d.ts +11 -0
- package/dist/data-layer.d.ts +7 -15
- package/dist/elements/om-map.d.ts +41 -1
- package/dist/geodesy.d.ts +2 -0
- package/dist/{geoparquet-CyWsYt9S.js → geoparquet-B_nO2OyP.js} +3 -3
- package/dist/{globe-view-Xelgj_KW.js → globe-view-BFUa9ksE.js} +1 -1
- package/dist/ground-controller.d.ts +39 -0
- package/dist/{hillshade-Zbg50lm6.js → hillshade-B_CxPhtA.js} +61 -64
- package/dist/{hillshade-shader-DI2uLSNU.js → hillshade-shader-r7GxxjXj.js} +12 -11
- package/dist/hillshade-shader.d.ts +2 -2
- package/dist/hillshade.d.ts +0 -29
- package/dist/{index-JFuN4DCn.js → index-A1FYw2dy.js} +1 -1
- package/dist/{index-BbVnkgld.js → index-BvNxS6dM.js} +38 -38
- package/dist/{index-ClAPAqcm.js → index-CObPGkze.js} +38 -38
- package/dist/{index-BL_YCKiW.js → index-CU7RnKnO.js} +62 -62
- package/dist/{index-6eeSlSqN.js → index-CgIuV5Oh.js} +3 -3
- package/dist/{index-DnCmvLuC.js → index-ChmxbIdj.js} +61 -61
- package/dist/{index-BwtXeP_F.js → index-DT5d7kFO.js} +1 -1
- package/dist/{index-CpFNIkOO.js → index-DWijIMti.js} +22217 -20712
- package/dist/{index-BtRsa5oc.js → index-YMu_yLXO.js} +18 -18
- package/dist/index.d.ts +1 -1
- package/dist/{lerc-C3SKC6CU.js → lerc-Bl4vym9y.js} +1 -1
- package/dist/onlymap.standalone.js +39073 -37485
- package/dist/onlymapjs.js +49 -49
- package/dist/plane-gpu/plane-basemap.d.ts +0 -14
- package/dist/{post-process-effect-C3P9VwC9.js → post-process-effect-gFGVlC77.js} +1 -1
- package/dist/programmatic.d.ts +3 -1
- package/dist/{raster-BgCnz9-Z.js → raster-1ShXyF12.js} +4 -4
- package/dist/{raster-pipeline-CKdpKgFo.js → raster-pipeline-BMS54TX2.js} +11 -11
- package/dist/runtime-core.d.ts +147 -0
- package/dist/sea-surface.d.ts +18 -0
- package/dist/terrain-derive.d.ts +39 -0
- package/dist/terrain-ground.d.ts +31 -0
- package/dist/terrain-heightfield.d.ts +17 -9
- package/dist/terrain-inspect-Cndlmxig.js +96 -0
- package/dist/terrain-inspect.d.ts +34 -0
- package/dist/terrain-nodata.d.ts +50 -0
- package/dist/terrain-priority.d.ts +92 -0
- package/dist/terrain-sample.d.ts +6 -0
- package/dist/terrain-skirt.d.ts +6140 -0
- package/dist/terrain-texture-mask.d.ts +40 -0
- package/dist/terrain-tint.d.ts +61 -0
- package/dist/terrain.d.ts +132 -8
- package/dist/{text-on-path-BpVLX8Yt.js → text-on-path-QInco4aP.js} +1 -1
- package/dist/tile-url.d.ts +94 -0
- package/dist/version.d.ts +1 -1
- package/dist/viewport-filter.d.ts +9 -0
- package/dist/volumetrics.d.ts +11 -0
- package/dist/{zarr-Cur_pzNa.js → zarr-CYD8fyBe.js} +2 -2
- package/docs/cartograph.md +2 -2
- package/llms.txt +2 -2
- package/onlymapjs.html-data.json +163 -3
- package/package.json +2 -1
- package/skills/onlymapjs/SKILL.md +6 -2
- package/skills/onlymapjs/references/syntax.md +12 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { P as h } from "./post-process-effect-
|
|
1
|
+
import { aC as j, aD as S, aE as A, aF as M, aG as L } from "./index-DWijIMti.js";
|
|
2
|
+
import { aH as B, aI as K, aJ as V, aK as X } from "./index-DWijIMti.js";
|
|
3
|
+
import { P as h } from "./post-process-effect-gFGVlC77.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); }
|
|
@@ -127,7 +127,7 @@ function z(o) {
|
|
|
127
127
|
s(), e.push({ kind: "neighbourhood", op: l });
|
|
128
128
|
}), s(), e;
|
|
129
129
|
}
|
|
130
|
-
function
|
|
130
|
+
function C(o, e) {
|
|
131
131
|
if (o.length === 0) return null;
|
|
132
132
|
const t = [], s = [], n = /* @__PURE__ */ new Map();
|
|
133
133
|
o.forEach((a, u) => {
|
|
@@ -185,7 +185,7 @@ ${_}
|
|
|
185
185
|
passCount: d.length
|
|
186
186
|
};
|
|
187
187
|
}
|
|
188
|
-
const
|
|
188
|
+
const T = /^\s*(-?[\d.]+)\s*(mm)?\s*$/i, N = /^\s*(-?[\d.]+)\s*(deg)?\s*$/i;
|
|
189
189
|
function E(o, e) {
|
|
190
190
|
if (o.kind === "color") {
|
|
191
191
|
const s = L(e);
|
|
@@ -194,7 +194,7 @@ function E(o, e) {
|
|
|
194
194
|
return [n / 255, l / 255, c / 255, r === void 0 ? 1 : r > 1 ? r / 255 : r];
|
|
195
195
|
}
|
|
196
196
|
if (o.kind === "length" || o.kind === "angle") {
|
|
197
|
-
const s = (o.kind === "length" ?
|
|
197
|
+
const s = (o.kind === "length" ? T : N).exec(e);
|
|
198
198
|
if (!s) return;
|
|
199
199
|
const n = Number(s[1]);
|
|
200
200
|
return Number.isFinite(n) ? n : void 0;
|
|
@@ -215,12 +215,12 @@ function P(o, e) {
|
|
|
215
215
|
}
|
|
216
216
|
return { op: o, values: s };
|
|
217
217
|
}
|
|
218
|
-
function
|
|
218
|
+
function F(o) {
|
|
219
219
|
if (!o || typeof o != "object") return !1;
|
|
220
220
|
const e = o;
|
|
221
221
|
return typeof e.name == "string" && typeof e.fs == "string" && Array.isArray(e.passes) && e.passes.length > 0;
|
|
222
222
|
}
|
|
223
|
-
function
|
|
223
|
+
function q(o) {
|
|
224
224
|
const e = [];
|
|
225
225
|
for (const t of Array.from(o.querySelectorAll(":scope > om-effect"))) {
|
|
226
226
|
const s = t.getAttribute("preset"), n = t.getAttribute("op"), l = t.querySelector(":scope > script[type='application/json']");
|
|
@@ -255,7 +255,7 @@ function J(o) {
|
|
|
255
255
|
console.warn(`[onlymapjs] <om-effect>'s inline module is not valid JSON — skipped. ${String(f)}`, t);
|
|
256
256
|
continue;
|
|
257
257
|
}
|
|
258
|
-
if (!
|
|
258
|
+
if (!F(c)) {
|
|
259
259
|
console.warn(
|
|
260
260
|
"[onlymapjs] <om-effect>'s inline module needs `name`, `fs` and a non-empty `passes` — skipped.",
|
|
261
261
|
t
|
|
@@ -277,14 +277,14 @@ function J(o) {
|
|
|
277
277
|
}
|
|
278
278
|
return e;
|
|
279
279
|
}
|
|
280
|
-
let
|
|
281
|
-
const
|
|
280
|
+
let R = 0;
|
|
281
|
+
const G = () => R++;
|
|
282
282
|
function D(o, e = S) {
|
|
283
283
|
const t = [], s = [];
|
|
284
284
|
let n = [];
|
|
285
|
-
const l =
|
|
285
|
+
const l = G(), c = () => {
|
|
286
286
|
if (n.length === 0) return;
|
|
287
|
-
const r =
|
|
287
|
+
const r = C(n, `omfx${l}_${t.length}`);
|
|
288
288
|
if (n = [], !r) return;
|
|
289
289
|
const i = { ...r.uniforms, pxPerMm: e }, f = new h(r.module, i);
|
|
290
290
|
s.push({ effect: f, uniforms: r.uniforms }), t.push(f);
|
|
@@ -309,14 +309,14 @@ function D(o, e = S) {
|
|
|
309
309
|
export {
|
|
310
310
|
S as CSS_PX_PER_MM,
|
|
311
311
|
M as EFFECT_PRESETS,
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
312
|
+
B as EFFECT_PRESET_NAMES,
|
|
313
|
+
K as OP_META,
|
|
314
|
+
V as OP_NAMES,
|
|
315
315
|
D as buildPostProcessEffects,
|
|
316
316
|
E as coerceParam,
|
|
317
|
-
|
|
317
|
+
X as expandPreset,
|
|
318
318
|
A as isEffectPreset,
|
|
319
319
|
b as opDef,
|
|
320
320
|
j as opMeta,
|
|
321
|
-
|
|
321
|
+
q as parseEffectEls
|
|
322
322
|
};
|
package/dist/index.d.ts
CHANGED
|
@@ -92,7 +92,7 @@ export { isStoreToken } from "./external-store";
|
|
|
92
92
|
export type { TokenStore, ViewOrigin, ViewportSnapshot, DataVersionSnapshot } from "./external-store";
|
|
93
93
|
export type { LayerMetaSnapshot } from "./ctx";
|
|
94
94
|
export type { Selection, PickMode, PickAtOptions, PickRectOptions, PickRect } from "./selection";
|
|
95
|
-
export type { CameraOptions } from "./runtime-core";
|
|
95
|
+
export type { Camera, CameraOptions } from "./runtime-core";
|
|
96
96
|
export type { MapViewport } from "./basemap";
|
|
97
97
|
export { registerAction } from "./actions";
|
|
98
98
|
export { distanceMeters, pathLengthMeters, ringAreaMeters2, ringPerimeterMeters, ringEnclosesPole, midpoint, getMeasureRadiusMeters, setMeasureRadiusMeters, WGS84_MEAN_RADIUS_M, type LngLat, } from "./geodesy";
|