@nika-js/onlymap 0.6.4 → 0.6.11

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 (41) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/README.md +7 -5
  3. package/dist/{LercDecode.es-D5in29tf.js → LercDecode.es-C331HMjV.js} +1 -1
  4. package/dist/attribute-resolution.d.ts +84 -6
  5. package/dist/{basemap-C0pFT3AO.js → basemap-NN5SYEaS.js} +1 -1
  6. package/dist/ctx.d.ts +3 -1
  7. package/dist/declarative-filter.d.ts +14 -5
  8. package/dist/elements/om-map.d.ts +20 -0
  9. package/dist/{geoparquet-By98JVB0.js → geoparquet-Dmyu5Oou.js} +1 -1
  10. package/dist/{index-Cxo9mCw_.js → index-BUp4hR6r.js} +17917 -17152
  11. package/dist/{index-tnlYDALL.js → index-CNxSRD27.js} +2 -2
  12. package/dist/{index-CqC4sW_k.js → index-CSVtCpQL.js} +1 -1
  13. package/dist/{index-olfncHIq.js → index-D28RTVKt.js} +1 -1
  14. package/dist/{index-Bx9GFkrn.js → index-_vNbcONa.js} +1 -1
  15. package/dist/index.d.ts +7 -1
  16. package/dist/ir-snapshot.d.ts +2 -1
  17. package/dist/ir.d.ts +47 -9
  18. package/dist/layer-registry.d.ts +7 -0
  19. package/dist/layers/marker-icons.d.ts +30 -0
  20. package/dist/layers/route-layer.d.ts +103 -0
  21. package/dist/layers/tracking-layer.d.ts +55 -0
  22. package/dist/{lerc-gKDDtc69.js → lerc-Cryu98-R.js} +2 -2
  23. package/dist/license.d.ts +11 -14
  24. package/dist/onlymap.standalone.js +47864 -47099
  25. package/dist/onlymapjs.js +64 -61
  26. package/dist/programmatic.d.ts +20 -1
  27. package/dist/providers.d.ts +48 -0
  28. package/dist/{raster-Cl5m3KsC.js → raster-BVzTnbhW.js} +2 -2
  29. package/dist/{raster-pipeline-hJGxIwYx.js → raster-pipeline-FAPzre9S.js} +1 -1
  30. package/dist/react/om-layer.d.ts +6 -2
  31. package/dist/react.js +54 -50
  32. package/dist/runtime-core.d.ts +21 -0
  33. package/dist/tracking-interpolation.d.ts +22 -0
  34. package/dist/version.d.ts +1 -1
  35. package/dist/{zarr-hRDavRGV.js → zarr-DCWSzKoG.js} +2 -2
  36. package/docs/routing.md +111 -0
  37. package/llms.txt +5 -4
  38. package/onlymapjs.html-data.json +77 -3
  39. package/package.json +1 -1
  40. package/skills/onlymapjs/SKILL.md +4 -2
  41. package/skills/onlymapjs/references/syntax.md +84 -4
@@ -1,5 +1,5 @@
1
- import { i as E, j as S, k as R, o as N, p as h, q as w, s as O, t as W, v as x, w as I, x as B, y as _, A as P, B as k, E as $, F as z, H as v, I as F, J as C, K as U, N as p, O as M } from "./index-Cxo9mCw_.js";
2
- import { P as $e, R as ze, _ as ve, Q as Ce, S as Ue, T as Me, U as je, X as De, Y as Je, Z as qe, $ as He, a0 as Ve, a1 as Ge, a2 as Ke, a3 as Qe, a4 as Xe, a5 as Ye, a6 as Ze, a7 as et, a8 as tt, a9 as nt, aa as rt, ab as at, ac as st, ad as ot } from "./index-Cxo9mCw_.js";
1
+ import { i as E, j as S, k as R, o as N, p as h, q as w, s as O, t as W, v as x, w as I, x as B, y as _, A as P, B as k, E as $, F as z, H as v, I as F, J as C, K as U, N as p, O as M } from "./index-BUp4hR6r.js";
2
+ import { P as $e, R as ze, _ as ve, Q as Ce, S as Ue, T as Me, U as je, X as De, Y as Je, Z as qe, $ as He, a0 as Ve, a1 as Ge, a2 as Ke, a3 as Qe, a4 as Xe, a5 as Ye, a6 as Ze, a7 as et, a8 as tt, a9 as nt, aa as rt, ab as at, ac as st, ad as ot } from "./index-BUp4hR6r.js";
3
3
  import { g as j, i as D } from "./table-accessors-CYWTzpQI.js";
4
4
  async function J(t, e, n = {}, r = {}) {
5
5
  const a = E(t), s = S.getWorkerFarm(n), { source: o } = n, c = { name: a, source: o };
@@ -1,4 +1,4 @@
1
- import { ae as _t, af as Ct } from "./index-Cxo9mCw_.js";
1
+ import { ae as _t, af as Ct } from "./index-BUp4hR6r.js";
2
2
  function Yt(e, r, t = 2, i, o = "xy") {
3
3
  const s = r && r.length, l = s ? r[0] * t : e.length;
4
4
  let c = Ut(e, 0, l, t, !0, i && i[0], o);
@@ -1,4 +1,4 @@
1
- import { ag as Be, ah as le, ai as ce, aj as De, ak as Oe, al as ke } from "./index-Cxo9mCw_.js";
1
+ import { ag as Be, ah as le, ai as ce, aj as De, ak as Oe, al as ke } from "./index-BUp4hR6r.js";
2
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";
@@ -1,4 +1,4 @@
1
- import { ak as Bt, ax as Xt, ay as Yt, az as Us } from "./index-Cxo9mCw_.js";
1
+ import { ak as Bt, ax as Xt, ay as Yt, az as Us } from "./index-BUp4hR6r.js";
2
2
  import { w as gs, t as Hs, f as Ws, m as Qs } from "./mgrs-BY9bIvp4.js";
3
3
  import { c as Xs } from "./convert-arrow-schema-DrAihRf9.js";
4
4
  import { y as Ys, A as bt, a as Ks, z as Vs, R as Zs } from "./recordbatch-Bpc0uxFn.js";
package/dist/index.d.ts CHANGED
@@ -32,6 +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 { registerRoutingProvider } from "./providers";
35
36
  import { configureTelemetry } from "./telemetry";
36
37
  import { configureLicense } from "./license";
37
38
  import { validateManifestString } from "./validation";
@@ -40,7 +41,7 @@ import { snapshotDescriptorIR } from "./programmatic";
40
41
  import { resolveImageOverlay } from "./image-overlay";
41
42
  export { registerLayer, getLayerSchema } from "./layer-registry";
42
43
  export type { LayerSchema, PropDescriptor, PropKind } from "./layer-registry";
43
- export type { LayerIR, LayerMeta, LayerFilter, LayerData, ColumnarData, LayerAssetState } from "./ir";
44
+ export type { LayerIR, LayerMeta, LayerFilter, LayerCategoryFilter, LayerData, ColumnarData, LayerAssetState } from "./ir";
44
45
  export { resolveImageOverlay, DRONE_SENSOR_DATABASE } from "./image-overlay";
45
46
  export type { ImageBounds, DroneExifData, DroneImageMetadata, DroneSensorDimensions, ResolveImageOverlayOptions, ResolvedImageOverlay, } from "./image-overlay";
46
47
  export { isColumnar, asRows, rowAt, normalizeData, arrowTableToColumnar } from "./data-layer";
@@ -58,6 +59,8 @@ export { LIGHTING_PRESET_NAMES, resolveLighting, solarAzElDegrees } from "./scen
58
59
  export type { LightingIR, LightingOptions, LightingPresetName } from "./scene-lighting";
59
60
  export { registerTerrain, getTerrain, parseTerrainAttrs } from "./terrain";
60
61
  export type { TerrainPreset, TerrainIR, ElevationDecoder, LayerTerrainMode } from "./terrain";
62
+ export { registerRoutingProvider, getRoutingProvider, lineStringLengthMeters } from "./providers";
63
+ export type { RoutingProvider, Route, RouteRequest, RouteWaypoint, RouteLeg } from "./providers";
61
64
  export type { SnapshotOptions } from "./snapshot";
62
65
  export { configureTelemetry } from "./telemetry";
63
66
  export type { IfcModel, IfcFeature, LoadIfcOptions } from "./ifc";
@@ -72,6 +75,8 @@ export type { Entitlements, LicenseIdentity } from "./license";
72
75
  export type { RuntimeContext } from "./ctx";
73
76
  export { MapController, descriptorToIR, snapshotDescriptorIR } from "./programmatic";
74
77
  export type { LayerDescriptor, MapControllerOptions, CameraState, OverlayPositioner, PickListener } from "./programmatic";
78
+ /** Multi-dimension GPU filter entry (spec: "Filtering") — `LayerDescriptor.filterFields`' element type, and the React adapter's `OmLayer` twin. */
79
+ export type { LayerFilterFieldSpec, LayerCategoryFilterFieldSpec } from "./attribute-resolution";
75
80
  export { releaseDataOwner } from "./data-layer";
76
81
  export type { DataTransportOwner } from "./data-layer";
77
82
  export { MANAGED_SLOTS, LEGACY_POSITION_ALIASES, ALL_POSITION_VALUES, FOLD_SIDES, resolveSlot, slotLayout, slotContainerStyle, foldSideForSlot, foldToggleSlot, foldDrawerStyle, foldPanelStyle, foldToggleStyle, resolveFoldBreakpointPx, shouldFoldAtWidth, DEFAULT_FOLD_BREAKPOINT_PX, FOLD_HYSTERESIS_PX, parseWidgetStyle, WIDGET_STYLE_KEY_NAMES, } from "./widget-layout";
@@ -125,6 +130,7 @@ export declare const OmMap: {
125
130
  registerSource: typeof registerSource;
126
131
  registerBasemap: typeof registerBasemap;
127
132
  registerTerrain: typeof registerTerrain;
133
+ registerRoutingProvider: typeof registerRoutingProvider;
128
134
  configureBasemap: typeof configureBasemap;
129
135
  configureData: typeof configureData;
130
136
  configureTelemetry: typeof configureTelemetry;
@@ -22,7 +22,7 @@
22
22
  * (snapshots are side-effect-free; a URL-backed layer shows the same empty
23
23
  * placeholder the live Q6 pre-fetch state has).
24
24
  */
25
- import type { LayerIR, LayerMeta, LayerFilter, LayerAssetState } from "./ir";
25
+ import type { LayerIR, LayerMeta, LayerFilter, LayerCategoryFilter, LayerAssetState } from "./ir";
26
26
  import type { Shape } from "./expr";
27
27
  export interface LayerIRSnapshot {
28
28
  id: string;
@@ -38,6 +38,7 @@ export interface LayerIRSnapshot {
38
38
  rows: number;
39
39
  meta: LayerMeta;
40
40
  filter?: LayerFilter;
41
+ categoryFilter?: LayerCategoryFilter;
41
42
  /** Per-layer terrain mode when authored (`terrain` attribute) — absent = the type default. */
42
43
  terrain?: "drape" | "offset" | "off";
43
44
  /**
package/dist/ir.d.ts CHANGED
@@ -30,18 +30,40 @@ export interface ColumnarData {
30
30
  /** A layer's resolved data: row objects (flat/geojson) or columns (columnar). */
31
31
  export type LayerData = unknown[] | ColumnarData;
32
32
  /**
33
- * The layer's active declarative filter (spec: "Filtering"), single-field
34
- * numeric only for now (`filterSize`/`categorySize` fixed at 1 — the spec's
35
- * own example is single-field; the "up to 4 dimensions" multi-field case is
36
- * a documented future extension, not implemented here). Carried on the IR
37
- * (not just `meta`) because `ctx.stats`/`ctx.dataInViewport` apply it
38
- * CPU-side by default (the "coherence rule") — it's operationally read, not
39
- * just display metadata.
33
+ * One numeric dimension of the layer's active declarative filter (spec:
34
+ * "Filtering"). Carried on the IR (not just `meta`) because `ctx.stats`/
35
+ * `ctx.dataInViewport` apply it CPU-side by default (the "coherence rule")
36
+ * it's operationally read, not just display metadata.
40
37
  */
41
- export interface LayerFilter {
38
+ export interface LayerFilterDimension {
42
39
  field: string;
43
40
  range: [number, number];
41
+ softRange?: [number, number];
44
42
  }
43
+ /**
44
+ * The layer's active declarative filter — one entry per numeric dimension,
45
+ * up to 4 (deck.gl `DataFilterExtension`'s own `filterSize` ceiling; a
46
+ * GLSL compile-time define, verified against the extension's own source —
47
+ * see `applyFilterWiring`'s doc comment). The single-field case (the
48
+ * original, still-primary authoring path via `filter-field`/`filter-range`)
49
+ * is simply a one-entry array — every consumer treats N=1 the same as
50
+ * N>1, no special-casing.
51
+ */
52
+ export type LayerFilter = LayerFilterDimension[];
53
+ /**
54
+ * One categorical dimension of the layer's active declarative filter — a
55
+ * discrete keep-list rather than a numeric range (deck.gl's `categorySize`
56
+ * slot, a SEPARATE bitmask mechanism from `filterSize`'s range test; values
57
+ * may be string or number). Carried on the IR for the same reason
58
+ * `LayerFilterDimension` is: `ctx.stats`/`ctx.dataInViewport` apply it
59
+ * CPU-side by default too.
60
+ */
61
+ export interface LayerCategoryFilterDimension {
62
+ field: string;
63
+ categories: (string | number)[];
64
+ }
65
+ /** The layer's active categorical filter — one entry per dimension, up to 4 (categorySize's own ceiling). Independent of, and combinable with, the numeric `LayerFilter`. */
66
+ export type LayerCategoryFilter = LayerCategoryFilterDimension[];
45
67
  /** Async non-row asset resolution carried by the IR (currently ImageOverlay EXIF only). */
46
68
  export interface LayerAssetState {
47
69
  kind: "image-overlay";
@@ -67,6 +89,20 @@ export interface LayerIR {
67
89
  shape: Shape;
68
90
  /** The raw `data` URL attribute, if any (ctx.layers metadata) — inline-JSON layers have none. */
69
91
  dataUrl?: string;
92
+ /**
93
+ * The authored live-source options that select this layer's transport
94
+ * (spec: "Live & Streaming Data"), retained on the IR rather than consumed
95
+ * by `getData` alone. Both front-ends populate it, so anything asking "is
96
+ * this layer polling?" reads resolved state instead of querying the DOM —
97
+ * which only the HTML lane has (see telemetry's per-layer snapshot).
98
+ * Absent when the layer declares none.
99
+ */
100
+ live?: {
101
+ source?: string;
102
+ key?: string;
103
+ flush?: string;
104
+ refresh?: string;
105
+ };
70
106
  /**
71
107
  * A `{z}/{x}/{y}` tile URL template (spec: "Tiled layers"): deck's `data`
72
108
  * for TileLayer/MVTLayer. When set, the renderer passes THIS as `data`
@@ -81,8 +117,10 @@ export interface LayerIR {
81
117
  */
82
118
  asset?: LayerAssetState;
83
119
  meta: LayerMeta;
84
- /** The layer's active declarative filter, if `filter-field`/`filter-range` are present. */
120
+ /** The layer's active declarative filter (one entry per dimension), if `filter-field`/`filter-fields` are present. */
85
121
  filter?: LayerFilter;
122
+ /** The layer's active categorical filter (one entry per dimension), if `filter-category`/`filter-category-fields` are present. Independent of `filter`. */
123
+ categoryFilter?: LayerCategoryFilter;
86
124
  /**
87
125
  * Per-layer terrain mode (spec: "Terrain") — the `terrain` attribute:
88
126
  * drape onto / sit on / ignore an active terrain surface. Absent = the
@@ -64,6 +64,13 @@ export interface LayerSchema {
64
64
  * one-source-of-truth reasoning as `carriesTileset`.
65
65
  */
66
66
  carriesGeoreference?: boolean;
67
+ /**
68
+ * Resolves its own route (spec: "Routing & Tracking") and supports the
69
+ * `onRouteResolved` deck prop — the runtime injects that hook only into
70
+ * these types (`Route`), same one-source-of-truth reasoning as
71
+ * `carriesTileset`. Drives `follow="fit-route"` camera behavior.
72
+ */
73
+ carriesRoute?: boolean;
67
74
  /** Layer-owned async asset resolver; keeps parse/runtime branching registry-driven rather than name-matched. */
68
75
  assetResolver?: "image-overlay";
69
76
  }
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Self-contained default marker icons (data: URIs) for Route/Tracking layers
3
+ * — no network fetch, no bundled asset, matching the library's own "sensible
4
+ * defaults" pillar (an author gets a working map with zero icon setup).
5
+ * Deliberately tiny/inline rather than a shared icon-atlas system: deck.gl's
6
+ * `IconLayer.getIcon` accepts a full per-object descriptor (`{url, width,
7
+ * height}`) and auto-packs it, so no `iconAtlas`/`iconMapping` is needed for
8
+ * this small a set.
9
+ */
10
+ export interface IconDescriptor {
11
+ url: string;
12
+ width: number;
13
+ height: number;
14
+ anchorY?: number;
15
+ }
16
+ /** A dropped-pin marker (origin/destination waypoints on a `Route` layer). Anchored at its point (bottom of the pin), not its center. */
17
+ export declare function pinIcon(color: string): IconDescriptor;
18
+ declare const DIRECTIONAL_SVGS: {
19
+ readonly arrow: "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"32\" height=\"32\" viewBox=\"0 0 32 32\">\n <circle cx=\"16\" cy=\"16\" r=\"14\" fill=\"COLOR\" fill-opacity=\"0.22\"/>\n <path d=\"M16 4 L24 26 L16 21 L8 26 Z\" fill=\"COLOR\"/>\n</svg>";
20
+ readonly car: "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"32\" height=\"32\" viewBox=\"0 0 32 32\">\n <circle cx=\"16\" cy=\"16\" r=\"14\" fill=\"COLOR\" fill-opacity=\"0.22\"/>\n <rect x=\"10\" y=\"4.5\" width=\"12\" height=\"23\" rx=\"4\" fill=\"COLOR\"/>\n <rect x=\"12\" y=\"9.5\" width=\"8\" height=\"4.5\" rx=\"1.4\" fill=\"#0b1220\" fill-opacity=\"0.55\"/>\n <rect x=\"12\" y=\"21\" width=\"8\" height=\"3.5\" rx=\"1.4\" fill=\"#0b1220\" fill-opacity=\"0.55\"/>\n</svg>";
21
+ readonly motorcycle: "<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"32\" height=\"32\" viewBox=\"0 0 32 32\">\n <circle cx=\"16\" cy=\"16\" r=\"14\" fill=\"COLOR\" fill-opacity=\"0.22\"/>\n <rect x=\"14.3\" y=\"3.5\" width=\"3.4\" height=\"7\" rx=\"1.7\" fill=\"#64748b\"/>\n <rect x=\"14.3\" y=\"21.5\" width=\"3.4\" height=\"7\" rx=\"1.7\" fill=\"#64748b\"/>\n <rect x=\"9.5\" y=\"9.5\" width=\"13\" height=\"2.6\" rx=\"1.3\" fill=\"COLOR\"/>\n <path d=\"M16 10.5 C19 12 19.4 14 19 17.5 C18.7 20.5 17.6 23 16 23 C14.4 23 13.3 20.5 13 17.5 C12.6 14 13 12 16 10.5 Z\" fill=\"COLOR\"/>\n <circle cx=\"16\" cy=\"16.5\" r=\"3\" fill=\"#f8fafc\" fill-opacity=\"0.92\"/>\n</svg>";
22
+ };
23
+ /** The `Tracking` layer's curated marker set — `icon` attribute values. */
24
+ export type TrackingIconName = keyof typeof DIRECTIONAL_SVGS;
25
+ export declare function isTrackingIconName(v: unknown): v is TrackingIconName;
26
+ /** A directional marker (a `Tracking` layer's moving entity) — every shape points "up" (north) at angle 0, rotated per-row via `getAngle`. Unknown names fall back to the arrow (validation warns at author time). */
27
+ export declare function directionalIcon(name: TrackingIconName | string, color: string): IconDescriptor;
28
+ /** Back-compat alias — the original arrow-only builder. */
29
+ export declare function arrowIcon(color: string): IconDescriptor;
30
+ export {};
@@ -0,0 +1,103 @@
1
+ /**
2
+ * RouteLayer — the Route half of "Routing & Tracking" (spec, v0.6.7).
3
+ * Expands into ordinary `PathLayer`/`IconLayer` instances, exactly the way
4
+ * `BIMLayer` expands into a `Tile3DLayer` — see that file's own doc comment
5
+ * for the pattern this mirrors (a `CompositeLayer` wrapping real deck.gl
6
+ * layers, not a new rendering path).
7
+ *
8
+ * Two authoring paths, mutually exclusive (`geometry` wins if both are
9
+ * present — validation.ts warns on the ambiguity):
10
+ *
11
+ * - `geometry` — an already-computed GeoJSON LineString. Resolves
12
+ * SYNCHRONOUSLY, no provider round-trip. Distance is derived locally
13
+ * (great-circle length); duration is left `NaN` — no speed model exists
14
+ * client-side, and a provider-computed route supplies its own.
15
+ * - `provider` + `origin` + `destination` (+ optional `waypoints`,
16
+ * `profile`) — resolves ASYNCHRONOUSLY via `RoutingProvider.computeRoute`
17
+ * (mirrors BIMLayer's `loadModel`: state, staleness checks, abort on
18
+ * supersede/teardown, `raiseError` on failure — see that file).
19
+ *
20
+ * `onRouteResolved` is injected by the runtime (`schema.carriesRoute`, the
21
+ * `onTilesetLoad`/`carriesTileset` precedent in runtime-core.ts) once a
22
+ * route is ready — that's what drives `follow="fit-route"` camera behavior.
23
+ * RouteLayer itself never touches the camera; camera side effects belong to
24
+ * runtime-core, not a deck.gl layer subclass.
25
+ */
26
+ import { CompositeLayer } from "@deck.gl/core";
27
+ import type { Layer } from "@deck.gl/core";
28
+ import { type Route, type RouteWaypoint } from "../providers";
29
+ export interface RouteBounds {
30
+ bounds: [[number, number], [number, number]];
31
+ }
32
+ type LineStringGeometry = {
33
+ type: "LineString";
34
+ coordinates: [number, number][];
35
+ };
36
+ /**
37
+ * Splits a polyline at the point on it nearest to `point` (spec: "Routing &
38
+ * Tracking / tail modes"). Real GPS fixes sit OFF the line, so the split is a
39
+ * projection onto the nearest segment, not an exact-vertex match. Longitudes
40
+ * are scaled by cos(mid-latitude) before comparing distances — raw degrees
41
+ * would overweight longitude away from the equator and can pick the wrong
42
+ * segment on north–south routes. Both halves include the projected point, so
43
+ * `taken` ends exactly where `remaining` begins. Pure and exported for
44
+ * direct unit testing (the `lerpAngle` precedent).
45
+ */
46
+ export declare function splitLineAtNearestPoint(coordinates: readonly (readonly [number, number])[], point: readonly [number, number]): {
47
+ taken: [number, number][];
48
+ remaining: [number, number][];
49
+ };
50
+ export interface RouteLayerProps {
51
+ geometry?: LineStringGeometry | string;
52
+ origin?: [number, number] | string;
53
+ destination?: [number, number] | string;
54
+ waypoints?: RouteWaypoint[] | string;
55
+ provider?: string;
56
+ profile?: "driving" | "walking" | "cycling";
57
+ color?: string;
58
+ casingColor?: string;
59
+ /**
60
+ * How the TRAVELED portion of the route renders, once `progress-from`
61
+ * supplies a current position (spec: "Routing & Tracking / tail modes"):
62
+ * "full" (default — whole route in `color`, the split is ignored),
63
+ * "dim" (operator view — traveled portion darkened, remaining in `color`),
64
+ * "none" (client view — only current position → destination renders, and
65
+ * the origin pin is dropped too: a start marker with no line reaching it
66
+ * reads as a stray point).
67
+ */
68
+ tail?: "full" | "dim" | "none";
69
+ /** Dim-mode tail color override; default derives a darkened `color`. */
70
+ tailColor?: string;
71
+ /** Id of the Tracking layer whose position splits this route — consumed by src/tracking-interpolation.ts (which patches `progressPosition` here per frame), not by this class directly. */
72
+ progressFrom?: string;
73
+ /** Injected per frame by src/tracking-interpolation.ts — never authored. */
74
+ progressPosition?: [number, number];
75
+ /** Injected by runtime-core.ts (schema.carriesRoute) — never authored. */
76
+ onRouteResolved?: (route: Route & RouteBounds) => void;
77
+ [prop: string]: unknown;
78
+ }
79
+ export declare class RouteLayer extends CompositeLayer<RouteLayerProps> {
80
+ static layerName: string;
81
+ static defaultProps: {
82
+ color: string;
83
+ casingColor: string;
84
+ profile: string;
85
+ };
86
+ state: {
87
+ route: Route | null;
88
+ loadingFor: string | null;
89
+ destroyed: boolean;
90
+ abort: AbortController | null;
91
+ };
92
+ initializeState(): void;
93
+ updateState({ props, oldProps }: {
94
+ props: RouteLayerProps;
95
+ oldProps: RouteLayerProps;
96
+ }): void;
97
+ finalizeState(): void;
98
+ private resolveRoute;
99
+ /** One casing-or-line `PathLayer` — the repeated shape of every stroke below. */
100
+ private strokeLayer;
101
+ renderLayers(): Layer[];
102
+ }
103
+ export {};
@@ -0,0 +1,55 @@
1
+ /**
2
+ * TrackingLayer — the Tracking half of "Routing & Tracking" (spec, v0.6.7).
3
+ * Wraps a single `IconLayer`: renders the CURRENT (or smoothly interpolating)
4
+ * position of one tracked entity, with bearing-derived rotation.
5
+ *
6
+ * v1 scope: ONE tracked entity per layer — the LAST row in `data` is "the"
7
+ * position. Fleet/multi-entity tracking on one layer is a documented
8
+ * follow-on, not built here (mirrors this codebase's own "v1 supports one,
9
+ * generalizing to many is a later tier" precedent — e.g. BIM model
10
+ * federation's "multiple co-registered models... NOT implemented").
11
+ *
12
+ * Position data arrives through the ORDINARY `data`/`source` mechanism (the
13
+ * design doc is explicit: a tracking feed is "a thin registerSource decoder
14
+ * over existing machinery", not a new subscription abstraction) —
15
+ * TrackingLayer itself knows nothing about where the data came from, same as
16
+ * any other curated layer reading `data`.
17
+ *
18
+ * Interpolation between updates and camera-follow are driven EXTERNALLY by
19
+ * `src/tracking-interpolation.ts` via the per-frame channel
20
+ * (`RuntimeCore.patchAnimatedProps`) — never inside this class, matching how
21
+ * RouteLayer never touches the camera itself either. When
22
+ * `interpolatedPosition` is present (injected only, never authored) it
23
+ * overrides the raw data-derived position; the un-interpolated fallback
24
+ * keeps this layer fully functional — just not smooth — even before the
25
+ * first interpolation frame lands (e.g. the very first fix, headless mode,
26
+ * or `prefers-reduced-motion`).
27
+ */
28
+ import { CompositeLayer } from "@deck.gl/core";
29
+ import type { Layer } from "@deck.gl/core";
30
+ export interface TrackingLayerProps {
31
+ data?: readonly unknown[];
32
+ getPosition?: (d: unknown, info: {
33
+ index: number;
34
+ data: readonly unknown[];
35
+ }) => [number, number];
36
+ bearingField?: string;
37
+ color?: string;
38
+ size?: number;
39
+ /** Marker shape: "arrow" (default), "car", or "motorcycle" — all drawn nose-up and baked in `color`, so rotation and tinting work identically. Unknown values fall back to the arrow (validation warns). */
40
+ icon?: string;
41
+ /** Injected by src/tracking-interpolation.ts — never authored. */
42
+ interpolatedPosition?: [number, number];
43
+ interpolatedBearing?: number;
44
+ [prop: string]: unknown;
45
+ }
46
+ export declare class TrackingLayer extends CompositeLayer<TrackingLayerProps> {
47
+ static layerName: string;
48
+ static defaultProps: {
49
+ bearingField: string;
50
+ color: string;
51
+ size: number;
52
+ icon: string;
53
+ };
54
+ renderLayers(): Layer[];
55
+ }
@@ -1,4 +1,4 @@
1
- import { C as a, D as s } from "./raster-Cl5m3KsC.js";
1
+ import { C as a, D as s } from "./raster-BVzTnbhW.js";
2
2
  const D = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3
3
  __proto__: null
4
4
  }, Symbol.toStringTag, { value: "Module" }));
@@ -8,7 +8,7 @@ var t;
8
8
  })(t || (t = {}));
9
9
  let l = !1;
10
10
  async function d() {
11
- const e = await import("./LercDecode.es-D5in29tf.js");
11
+ const e = await import("./LercDecode.es-C331HMjV.js");
12
12
  return l || (await e.load(), l = !0), e;
13
13
  }
14
14
  async function i(e, r) {
package/dist/license.d.ts CHANGED
@@ -15,20 +15,17 @@
15
15
  * packaged-app `apps` claim — they MAY appear in markup, unlike data
16
16
  * credentials.
17
17
  *
18
- * The two claims are NOT equally enforceable, and neither is a security
19
- * boundary. `domains` is checked against a hostname the browser pins;
20
- * `apps` is checked against an identifier the caller passes in, so any page
21
- * holding the key can assert any app id (bundle ids are public and app
22
- * bundles unpack trivially). Native shells must therefore read app identity
23
- * from trusted platform APIs, never from bridge JSON controlled by page
24
- * code — but that is a host obligation this module cannot verify. No
25
- * origin-sniffing gate guards it either: packaged hosts land on origins
26
- * indistinguishable from the web (Capacitor Android serves http://localhost,
27
- * WebViewAssetLoader serves any configured https domain), so a heuristic
28
- * would downgrade paying customers to the free tier — and the packaged
29
- * contexts worth protecting already lift every cap as DEV contexts below.
30
- * Both claims are deterrents that make reuse attributable via `keyId`;
31
- * packaged-app enforcement is LEGAL, not technical (see LICENSE.md).
18
+ * Both claims are deployment SCOPING, not access control: keys are
19
+ * publishable by design, and commercial-use enforcement is LEGAL rather than
20
+ * technical (see LICENSE.md) `keyId` is what makes a deployment
21
+ * attributable. `appId` reaches this module as a plain argument whose
22
+ * provenance it cannot verify, so a native host MUST source it from trusted
23
+ * platform build metadata and never from page script or bridge JSON.
24
+ *
25
+ * NOTE: this header is emitted verbatim into the published dist/license.d.ts.
26
+ * Keep it to the contract a consumer needs. Comparative analysis of how far
27
+ * each claim can be trusted, and why no origin heuristic guards the app
28
+ * claim, lives in agent-map-library-architecture.md (internal, not shipped).
32
29
  *
33
30
  * Decisions (spec, RESOLVED 2026-07-14; REVISED 2026-08-05): free tier =
34
31
  * 5 layers / 25k rows per layer / 20 MB fetch; any paid plan hides the