@mailwoman/react 9.2.0 → 9.4.0
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/README.md +1 -1
- package/fonts.css +59 -0
- package/lib/common/About.tsx +89 -0
- package/{common → lib/common}/CopyButton.tsx +1 -1
- package/{common → lib/common}/KindBadge.tsx +2 -7
- package/{common → lib/common}/LoadingIndicator.tsx +1 -1
- package/lib/common/confidence-tiers.ts +50 -0
- package/lib/common/text-tokens.ts +88 -0
- package/{index.ts → lib/index.ts} +44 -42
- package/{map → lib/map}/CompareToggle.tsx +2 -2
- package/{map/GeocoderDemo.tsx → lib/map/Geocoder.tsx} +45 -44
- package/{map/DemoControls.tsx → lib/map/GeocoderControls.tsx} +19 -19
- package/{map/DemoMap.tsx → lib/map/MapCanvas.tsx} +16 -16
- package/{map → lib/map}/OverlayLayers.tsx +3 -3
- package/{map → lib/map}/PlaceAutocomplete.tsx +2 -2
- package/{map → lib/map}/PlaceMarker.tsx +1 -1
- package/{map → lib/map}/ResolvedPlaceLayers.tsx +5 -4
- package/{map → lib/map}/ResultCamera.tsx +3 -3
- package/{map → lib/map}/ResultOverlay.tsx +2 -2
- package/{map → lib/map}/ResultPanel.tsx +4 -3
- package/{map → lib/map}/VersionPicker.tsx +3 -3
- package/lib/map/fake-runtime.ts +122 -0
- package/{map → lib/map}/index.ts +26 -26
- package/lib/map/map-debug.ts +51 -0
- package/{map → lib/map}/place-render.ts +5 -4
- package/{map → lib/map}/types.ts +51 -46
- package/{map/useDemoGeocode.ts → lib/map/useGeocode.ts} +11 -11
- package/{map → lib/map}/useMapPlaceRender.ts +2 -2
- package/{map → lib/map}/usePlaceAutocomplete.ts +2 -2
- package/{pipeline → lib/pipeline}/CandidatePicker.tsx +2 -2
- package/{pipeline → lib/pipeline}/ComponentTable.tsx +1 -1
- package/lib/pipeline/ConfidenceCell.tsx +31 -0
- package/lib/pipeline/FailureDiagnostic.tsx +56 -0
- package/{pipeline → lib/pipeline}/PipelineExplorer.tsx +5 -4
- package/{pipeline → lib/pipeline}/QueryForm.tsx +2 -2
- package/{pipeline → lib/pipeline}/ResolvedPlace.tsx +17 -4
- package/lib/pipeline/SpanHighlight.tsx +97 -0
- package/lib/pipeline/TimingPanel.tsx +65 -0
- package/lib/pipeline/TreeView.tsx +55 -0
- package/{pipeline → lib/pipeline}/copy.ts +1 -1
- package/{pipeline → lib/pipeline}/presets.ts +2 -1
- package/{pipeline → lib/pipeline}/types.ts +2 -75
- package/{pipeline → lib/pipeline}/useParsePipeline.ts +2 -1
- package/{poi → lib/poi}/LiveResultsBlock.tsx +2 -2
- package/{poi → lib/poi}/POIExplorer.tsx +4 -3
- package/{poi → lib/poi}/SubjectPanel.tsx +1 -1
- package/{poi → lib/poi}/runtime.ts +3 -3
- package/{poi → lib/poi}/types.ts +3 -2
- package/{poi → lib/poi}/usePOISearch.ts +5 -5
- package/{runtime/useDemoRuntime.ts → lib/runtime/useReleaseRuntime.ts} +24 -26
- package/out/common/About.d.ts +12 -0
- package/out/common/About.d.ts.map +1 -0
- package/out/common/About.js +5 -0
- package/out/common/About.js.map +1 -0
- package/out/common/ClientOnly.d.ts.map +1 -1
- package/out/common/ClientOnly.js.map +1 -1
- package/out/common/CopyButton.d.ts.map +1 -1
- package/out/common/CopyButton.js +1 -1
- package/out/common/CopyButton.js.map +1 -1
- package/out/common/KindBadge.d.ts +2 -9
- package/out/common/KindBadge.d.ts.map +1 -1
- package/out/common/KindBadge.js.map +1 -1
- package/out/common/LoadingIndicator.d.ts.map +1 -1
- package/out/common/LoadingIndicator.js +1 -1
- package/out/common/LoadingIndicator.js.map +1 -1
- package/out/common/PresetChips.d.ts.map +1 -1
- package/out/common/PresetChips.js.map +1 -1
- package/out/common/confidence-tiers.d.ts +36 -0
- package/out/common/confidence-tiers.d.ts.map +1 -0
- package/out/common/confidence-tiers.js +42 -0
- package/out/common/confidence-tiers.js.map +1 -0
- package/out/common/cx.d.ts.map +1 -1
- package/out/common/cx.js.map +1 -1
- package/out/common/text-tokens.d.ts +46 -0
- package/out/common/text-tokens.d.ts.map +1 -0
- package/out/common/text-tokens.js +52 -0
- package/out/common/text-tokens.js.map +1 -0
- package/out/common/useClipboard.d.ts.map +1 -1
- package/out/common/useClipboard.js.map +1 -1
- package/out/common/useDebouncedValue.d.ts.map +1 -1
- package/out/common/useDebouncedValue.js.map +1 -1
- package/out/index.d.ts +27 -18
- package/out/index.d.ts.map +1 -1
- package/out/index.js +16 -10
- package/out/index.js.map +1 -1
- package/out/map/BackendControl.d.ts.map +1 -1
- package/out/map/BackendControl.js.map +1 -1
- package/out/map/CompareToggle.d.ts +2 -2
- package/out/map/CompareToggle.d.ts.map +1 -1
- package/out/map/CompareToggle.js.map +1 -1
- package/out/map/{GeocoderDemo.d.ts → Geocoder.d.ts} +17 -17
- package/out/map/Geocoder.d.ts.map +1 -0
- package/out/map/{GeocoderDemo.js → Geocoder.js} +30 -30
- package/out/map/Geocoder.js.map +1 -0
- package/out/map/GeocoderControls.d.ts +63 -0
- package/out/map/GeocoderControls.d.ts.map +1 -0
- package/out/map/{DemoControls.js → GeocoderControls.js} +2 -2
- package/out/map/GeocoderControls.js.map +1 -0
- package/out/map/{DemoMap.d.ts → MapCanvas.d.ts} +16 -16
- package/out/map/MapCanvas.d.ts.map +1 -0
- package/out/map/{DemoMap.js → MapCanvas.js} +2 -2
- package/out/map/MapCanvas.js.map +1 -0
- package/out/map/OverlayLayers.d.ts +3 -3
- package/out/map/OverlayLayers.d.ts.map +1 -1
- package/out/map/OverlayLayers.js +2 -2
- package/out/map/OverlayLayers.js.map +1 -1
- package/out/map/PlaceAutocomplete.d.ts +1 -1
- package/out/map/PlaceAutocomplete.d.ts.map +1 -1
- package/out/map/PlaceAutocomplete.js +1 -1
- package/out/map/PlaceAutocomplete.js.map +1 -1
- package/out/map/PlaceMarker.d.ts +1 -1
- package/out/map/PlaceMarker.d.ts.map +1 -1
- package/out/map/PlaceMarker.js.map +1 -1
- package/out/map/ResolvedPlaceLayers.d.ts +4 -4
- package/out/map/ResolvedPlaceLayers.d.ts.map +1 -1
- package/out/map/ResolvedPlaceLayers.js.map +1 -1
- package/out/map/ResultCamera.d.ts +3 -3
- package/out/map/ResultCamera.d.ts.map +1 -1
- package/out/map/ResultCamera.js +2 -2
- package/out/map/ResultCamera.js.map +1 -1
- package/out/map/ResultOverlay.d.ts +2 -2
- package/out/map/ResultOverlay.d.ts.map +1 -1
- package/out/map/ResultOverlay.js.map +1 -1
- package/out/map/ResultPanel.d.ts +2 -2
- package/out/map/ResultPanel.d.ts.map +1 -1
- package/out/map/ResultPanel.js +1 -1
- package/out/map/ResultPanel.js.map +1 -1
- package/out/map/VersionPicker.d.ts +3 -3
- package/out/map/VersionPicker.d.ts.map +1 -1
- package/out/map/VersionPicker.js.map +1 -1
- package/out/map/fake-runtime.d.ts +38 -0
- package/out/map/fake-runtime.d.ts.map +1 -0
- package/out/map/fake-runtime.js +107 -0
- package/out/map/fake-runtime.js.map +1 -0
- package/out/map/geometry.d.ts.map +1 -1
- package/out/map/geometry.js.map +1 -1
- package/out/map/index.d.ts +19 -19
- package/out/map/index.d.ts.map +1 -1
- package/out/map/index.js +11 -11
- package/out/map/index.js.map +1 -1
- package/out/map/map-debug.d.ts +31 -0
- package/out/map/map-debug.d.ts.map +1 -0
- package/out/map/map-debug.js +31 -0
- package/out/map/map-debug.js.map +1 -0
- package/out/map/place-render.d.ts +3 -3
- package/out/map/place-render.d.ts.map +1 -1
- package/out/map/place-render.js +2 -2
- package/out/map/place-render.js.map +1 -1
- package/out/map/types.d.ts +50 -46
- package/out/map/types.d.ts.map +1 -1
- package/out/map/types.js +6 -6
- package/out/map/types.js.map +1 -1
- package/out/map/useCompareState.d.ts.map +1 -1
- package/out/map/useCompareState.js.map +1 -1
- package/out/map/{useDemoGeocode.d.ts → useGeocode.d.ts} +11 -11
- package/out/map/useGeocode.d.ts.map +1 -0
- package/out/map/{useDemoGeocode.js → useGeocode.js} +5 -5
- package/out/map/useGeocode.js.map +1 -0
- package/out/map/useMapPlaceRender.d.ts +1 -1
- package/out/map/useMapPlaceRender.d.ts.map +1 -1
- package/out/map/useMapPlaceRender.js +1 -1
- package/out/map/useMapPlaceRender.js.map +1 -1
- package/out/map/usePlaceAutocomplete.d.ts +1 -1
- package/out/map/usePlaceAutocomplete.d.ts.map +1 -1
- package/out/map/usePlaceAutocomplete.js +1 -1
- package/out/map/usePlaceAutocomplete.js.map +1 -1
- package/out/pipeline/CandidatePicker.d.ts +1 -1
- package/out/pipeline/CandidatePicker.d.ts.map +1 -1
- package/out/pipeline/CandidatePicker.js +1 -1
- package/out/pipeline/CandidatePicker.js.map +1 -1
- package/out/pipeline/ComponentTable.d.ts +1 -1
- package/out/pipeline/ComponentTable.d.ts.map +1 -1
- package/out/pipeline/ComponentTable.js.map +1 -1
- package/out/pipeline/ConfidenceCell.d.ts +2 -2
- package/out/pipeline/ConfidenceCell.d.ts.map +1 -1
- package/out/pipeline/ConfidenceCell.js +5 -17
- package/out/pipeline/ConfidenceCell.js.map +1 -1
- package/out/pipeline/FailureDiagnostic.d.ts +15 -0
- package/out/pipeline/FailureDiagnostic.d.ts.map +1 -0
- package/out/pipeline/FailureDiagnostic.js +21 -0
- package/out/pipeline/FailureDiagnostic.js.map +1 -0
- package/out/pipeline/PipelineExplorer.d.ts +1 -1
- package/out/pipeline/PipelineExplorer.d.ts.map +1 -1
- package/out/pipeline/PipelineExplorer.js +3 -3
- package/out/pipeline/PipelineExplorer.js.map +1 -1
- package/out/pipeline/QueryForm.d.ts +2 -2
- package/out/pipeline/QueryForm.d.ts.map +1 -1
- package/out/pipeline/QueryForm.js.map +1 -1
- package/out/pipeline/ResolvedPlace.d.ts +1 -1
- package/out/pipeline/ResolvedPlace.d.ts.map +1 -1
- package/out/pipeline/ResolvedPlace.js +4 -10
- package/out/pipeline/ResolvedPlace.js.map +1 -1
- package/out/pipeline/SpanHighlight.d.ts +23 -0
- package/out/pipeline/SpanHighlight.d.ts.map +1 -0
- package/out/pipeline/SpanHighlight.js +31 -0
- package/out/pipeline/SpanHighlight.js.map +1 -0
- package/out/pipeline/TimingPanel.d.ts +16 -0
- package/out/pipeline/TimingPanel.d.ts.map +1 -0
- package/out/pipeline/TimingPanel.js +20 -0
- package/out/pipeline/TimingPanel.js.map +1 -0
- package/out/pipeline/TreeView.d.ts +17 -0
- package/out/pipeline/TreeView.d.ts.map +1 -0
- package/out/pipeline/TreeView.js +15 -0
- package/out/pipeline/TreeView.js.map +1 -0
- package/out/pipeline/copy.d.ts +1 -1
- package/out/pipeline/copy.d.ts.map +1 -1
- package/out/pipeline/copy.js.map +1 -1
- package/out/pipeline/presets.d.ts.map +1 -1
- package/out/pipeline/presets.js +2 -1
- package/out/pipeline/presets.js.map +1 -1
- package/out/pipeline/types.d.ts +2 -68
- package/out/pipeline/types.d.ts.map +1 -1
- package/out/pipeline/types.js +1 -1
- package/out/pipeline/types.js.map +1 -1
- package/out/pipeline/useParsePipeline.d.ts +2 -1
- package/out/pipeline/useParsePipeline.d.ts.map +1 -1
- package/out/pipeline/useParsePipeline.js.map +1 -1
- package/out/poi/AbstainPanel.d.ts.map +1 -1
- package/out/poi/AbstainPanel.js.map +1 -1
- package/out/poi/LiveResultsBlock.d.ts +1 -1
- package/out/poi/LiveResultsBlock.d.ts.map +1 -1
- package/out/poi/LiveResultsBlock.js +1 -1
- package/out/poi/LiveResultsBlock.js.map +1 -1
- package/out/poi/OverpassBlock.d.ts.map +1 -1
- package/out/poi/OverpassBlock.js.map +1 -1
- package/out/poi/POIExplorer.d.ts +1 -1
- package/out/poi/POIExplorer.d.ts.map +1 -1
- package/out/poi/POIExplorer.js +2 -2
- package/out/poi/POIExplorer.js.map +1 -1
- package/out/poi/QueryInput.d.ts.map +1 -1
- package/out/poi/QueryInput.js.map +1 -1
- package/out/poi/SubjectPanel.d.ts +1 -1
- package/out/poi/SubjectPanel.d.ts.map +1 -1
- package/out/poi/SubjectPanel.js.map +1 -1
- package/out/poi/runtime.d.ts +1 -1
- package/out/poi/runtime.d.ts.map +1 -1
- package/out/poi/runtime.js.map +1 -1
- package/out/poi/types.d.ts +3 -2
- package/out/poi/types.d.ts.map +1 -1
- package/out/poi/types.js +1 -1
- package/out/poi/types.js.map +1 -1
- package/out/poi/usePOISearch.d.ts +1 -1
- package/out/poi/usePOISearch.d.ts.map +1 -1
- package/out/poi/usePOISearch.js +4 -4
- package/out/poi/usePOISearch.js.map +1 -1
- package/out/runtime/{useDemoRuntime.d.ts → useReleaseRuntime.d.ts} +20 -22
- package/out/runtime/useReleaseRuntime.d.ts.map +1 -0
- package/out/runtime/{useDemoRuntime.js → useReleaseRuntime.js} +6 -6
- package/out/runtime/useReleaseRuntime.js.map +1 -0
- package/package.json +221 -34
- package/styleframe.config.ts +321 -0
- package/styles.css +1074 -664
- package/tokens/index.css +115 -0
- package/tokens/tokens.json +521 -0
- package/tokens/tokens.resolver.json +185 -0
- package/out/map/DemoControls.d.ts +0 -64
- package/out/map/DemoControls.d.ts.map +0 -1
- package/out/map/DemoControls.js.map +0 -1
- package/out/map/DemoMap.d.ts.map +0 -1
- package/out/map/DemoMap.js.map +0 -1
- package/out/map/GeocoderDemo.d.ts.map +0 -1
- package/out/map/GeocoderDemo.js.map +0 -1
- package/out/map/useDemoGeocode.d.ts.map +0 -1
- package/out/map/useDemoGeocode.js.map +0 -1
- package/out/runtime/useDemoRuntime.d.ts.map +0 -1
- package/out/runtime/useDemoRuntime.js.map +0 -1
- package/pipeline/ConfidenceCell.tsx +0 -43
- /package/{common → lib/common}/ClientOnly.tsx +0 -0
- /package/{common → lib/common}/PresetChips.tsx +0 -0
- /package/{common → lib/common}/cx.ts +0 -0
- /package/{common → lib/common}/useClipboard.ts +0 -0
- /package/{common → lib/common}/useDebouncedValue.ts +0 -0
- /package/{map → lib/map}/BackendControl.tsx +0 -0
- /package/{map → lib/map}/geometry.ts +0 -0
- /package/{map → lib/map}/useCompareState.ts +0 -0
- /package/{poi → lib/poi}/AbstainPanel.tsx +0 -0
- /package/{poi → lib/poi}/OverpassBlock.tsx +0 -0
- /package/{poi → lib/poi}/QueryInput.tsx +0 -0
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
* @license AGPL-3.0
|
|
4
4
|
* @author Teffen Ellis, et al.
|
|
5
5
|
*
|
|
6
|
-
* `
|
|
7
|
-
* inline doc-embeds via `
|
|
6
|
+
* `useReleaseRuntime` — the headless load-orchestration hook shared by every mailwoman browser surface (the
|
|
7
|
+
* inline doc-embeds via `RuntimeEmbed`, and the geocoder). It owns the version-selection state
|
|
8
8
|
* machine, the per-version load SEQUENCING, cancellation, and the ready / loading / error state — but
|
|
9
9
|
* NOTHING model- or map-specific. The actual asset fetchers (the ONNX classifier factory, the httpvfs
|
|
10
10
|
* WOF opener, the FST fetch, the releases.json fetch) are INJECTED by the host as async functions, so
|
|
11
11
|
* this module imports only React: no `onnxruntime-web`, no `sql.js-httpvfs`, no `maplibre-gl`, no
|
|
12
12
|
* `fetch`-specific plumbing. That keeps it node-import-safe and root-exportable from
|
|
13
|
-
* `@mailwoman/react` — the exact
|
|
13
|
+
* `@mailwoman/react` — the exact interface `PipelineRuntime` established, generalized to the loader itself.
|
|
14
14
|
*
|
|
15
15
|
* The hook is generic over `TAssets` (the opaque bundle the host's `loadAssets` returns — classifier,
|
|
16
16
|
* FST, WOF lookup, calibrator, …) and `TRelease` (the host's release-manifest entry). The package
|
|
@@ -22,7 +22,7 @@ import { useCallback, useEffect, useMemo, useRef, useState } from "react"
|
|
|
22
22
|
/**
|
|
23
23
|
* The minimal contract a release-manifest entry must satisfy. Hosts extend this with their own fields.
|
|
24
24
|
*/
|
|
25
|
-
export interface
|
|
25
|
+
export interface ReleaseBase {
|
|
26
26
|
/**
|
|
27
27
|
* The version tag this entry describes (matched against `selectedVersion`).
|
|
28
28
|
*/
|
|
@@ -36,7 +36,7 @@ export interface DemoReleaseBase {
|
|
|
36
36
|
/**
|
|
37
37
|
* The releases manifest the host fetches — the default version plus the selectable release entries.
|
|
38
38
|
*/
|
|
39
|
-
export interface
|
|
39
|
+
export interface ReleaseManifest<TRelease extends ReleaseBase = ReleaseBase> {
|
|
40
40
|
/**
|
|
41
41
|
* The version selected on first load (before the user picks another).
|
|
42
42
|
*/
|
|
@@ -52,7 +52,7 @@ export interface DemoManifest<TRelease extends DemoReleaseBase = DemoReleaseBase
|
|
|
52
52
|
* staged step labels/index THROUGH these setters (all no-op once the load is superseded/aborted), while the hook owns
|
|
53
53
|
* the terminal state (revealing the assets + clearing progress on success, surfacing the error on failure).
|
|
54
54
|
*/
|
|
55
|
-
export interface
|
|
55
|
+
export interface AssetsLoadContext {
|
|
56
56
|
/**
|
|
57
57
|
* Aborts when this load is superseded (version/backend switch) or the provider unmounts.
|
|
58
58
|
*/
|
|
@@ -82,18 +82,18 @@ export interface DemoAssetsLoadContext {
|
|
|
82
82
|
/**
|
|
83
83
|
* The injected loaders the hook orchestrates. Nothing here is model- or map-aware — the host owns all that.
|
|
84
84
|
*/
|
|
85
|
-
export interface
|
|
85
|
+
export interface ReleaseRuntimeConfig<TAssets, TRelease extends ReleaseBase = ReleaseBase> {
|
|
86
86
|
/**
|
|
87
|
-
* Fetch + normalize the releases manifest. Returns `null` when no manifest is available (the
|
|
88
|
-
* selectable). Rejecting surfaces `errorMessage`. Runs once on mount.
|
|
87
|
+
* Fetch + normalize the releases manifest. Returns `null` when no manifest is available (the surface then shows
|
|
88
|
+
* nothing selectable). Rejecting surfaces `errorMessage`. Runs once on mount.
|
|
89
89
|
*/
|
|
90
|
-
loadManifest: (signal: AbortSignal) => Promise<
|
|
90
|
+
loadManifest: (signal: AbortSignal) => Promise<ReleaseManifest<TRelease> | null>
|
|
91
91
|
/**
|
|
92
92
|
* Load the full asset bundle for one release — the classifier, FST, WOF lookup, calibrator, whatever the host needs.
|
|
93
93
|
* Runs on every version or `forceWASM` change. Report progress via `ctx`; return the bundle. Rejecting surfaces
|
|
94
94
|
* `errorMessage`. Bail early when `ctx.signal.aborted` — the hook discards a superseded result regardless.
|
|
95
95
|
*/
|
|
96
|
-
loadAssets: (release: TRelease, ctx:
|
|
96
|
+
loadAssets: (release: TRelease, ctx: AssetsLoadContext) => Promise<TAssets>
|
|
97
97
|
/**
|
|
98
98
|
* The progress line shown before the manifest arrives. @default "Loading releases…"
|
|
99
99
|
*/
|
|
@@ -101,19 +101,17 @@ export interface DemoRuntimeConfig<TAssets, TRelease extends DemoReleaseBase = D
|
|
|
101
101
|
}
|
|
102
102
|
|
|
103
103
|
/**
|
|
104
|
-
* The state `
|
|
104
|
+
* The state `useReleaseRuntime` produces — the load-orchestration state a surface renders + re-projects.
|
|
105
105
|
*
|
|
106
|
-
*
|
|
107
|
-
*
|
|
108
|
-
*
|
|
109
|
-
* this loader state (assets + backend + version) with the map surface (style, overlays, bias, parse) — see the map
|
|
110
|
-
* subpath's `DemoRuntime`.
|
|
106
|
+
* This is the LOADER STATE, deliberately distinct from {@link GeocoderRuntime} (the injected runtime contract
|
|
107
|
+
* `<Geocoder>` consumes). A host builds a {@link GeocoderRuntime} by pairing this loader state (assets + backend +
|
|
108
|
+
* version) with the map surface (style, overlays, bias, parse) — see the map subpath's `GeocoderRuntime`.
|
|
111
109
|
*/
|
|
112
|
-
export interface
|
|
110
|
+
export interface ReleaseLoaderState<TAssets, TRelease extends ReleaseBase = ReleaseBase> {
|
|
113
111
|
/**
|
|
114
112
|
* The releases manifest, once fetched.
|
|
115
113
|
*/
|
|
116
|
-
manifest:
|
|
114
|
+
manifest: ReleaseManifest<TRelease> | null
|
|
117
115
|
/**
|
|
118
116
|
* The currently-selected version, or `null` before the manifest resolves.
|
|
119
117
|
*/
|
|
@@ -169,14 +167,14 @@ export interface DemoLoaderState<TAssets, TRelease extends DemoReleaseBase = Dem
|
|
|
169
167
|
*
|
|
170
168
|
* Sequence: on mount `loadManifest` runs and its `defaultVersion` becomes the selection; each version (or `forceWASM`)
|
|
171
169
|
* change reloads the bundle via `loadAssets`, the previous load aborted first. The assets are revealed ATOMICALLY when
|
|
172
|
-
* `loadAssets` resolves (so `ready` flips exactly once per load), and consumers
|
|
170
|
+
* `loadAssets` resolves (so `ready` flips exactly once per load), and consumers wait on `ready`.
|
|
173
171
|
*/
|
|
174
|
-
export function
|
|
175
|
-
config:
|
|
176
|
-
):
|
|
172
|
+
export function useReleaseRuntime<TAssets, TRelease extends ReleaseBase = ReleaseBase>(
|
|
173
|
+
config: ReleaseRuntimeConfig<TAssets, TRelease>
|
|
174
|
+
): ReleaseLoaderState<TAssets, TRelease> {
|
|
177
175
|
const { initialProgress = "Loading releases…" } = config
|
|
178
176
|
|
|
179
|
-
const [manifest, setManifest] = useState<
|
|
177
|
+
const [manifest, setManifest] = useState<ReleaseManifest<TRelease> | null>(null)
|
|
180
178
|
const [selectedVersion, setSelectedVersion] = useState<string | null>(null)
|
|
181
179
|
const [assets, setAssets] = useState<TAssets | null>(null)
|
|
182
180
|
const [loadingProgress, setLoadingProgress] = useState<string>(initialProgress)
|
|
@@ -194,7 +192,7 @@ export function useDemoRuntime<TAssets, TRelease extends DemoReleaseBase = DemoR
|
|
|
194
192
|
// Latest manifest for the version-load effect, so it can resolve the release WITHOUT depending on `manifest`
|
|
195
193
|
// identity — which would double-fire the load the instant the manifest first arrives (the selection transition
|
|
196
194
|
// null → defaultVersion already fires it once).
|
|
197
|
-
const manifestRef = useRef<
|
|
195
|
+
const manifestRef = useRef<ReleaseManifest<TRelease> | null>(null)
|
|
198
196
|
|
|
199
197
|
useEffect(() => {
|
|
200
198
|
loadManifestRef.current = config.loadManifest
|
|
@@ -249,7 +247,7 @@ export function useDemoRuntime<TAssets, TRelease extends DemoReleaseBase = DemoR
|
|
|
249
247
|
setLoadingStepLabels([])
|
|
250
248
|
setActiveBackend("")
|
|
251
249
|
|
|
252
|
-
const ctx:
|
|
250
|
+
const ctx: AssetsLoadContext = {
|
|
253
251
|
signal,
|
|
254
252
|
forceWASM,
|
|
255
253
|
setProgress: (progress) => guard(() => setLoadingProgress(progress)),
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* `About` — the collapsible explainer for the browser geocoder: the neural model, the confidence colours, the
|
|
7
|
+
* gazetteer resolver, the byte-range database and the FST prior. Prose about the product a host places above or
|
|
8
|
+
* beside the geocoder; it renders nothing live.
|
|
9
|
+
*/
|
|
10
|
+
import type { ReactNode } from "react";
|
|
11
|
+
export declare function About(): ReactNode;
|
|
12
|
+
//# sourceMappingURL=About.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"About.d.ts","sourceRoot":"","sources":["../../lib/common/About.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,wBAAgB,KAAK,IAAI,SAAS,CA4EjC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
export function About() {
|
|
3
|
+
return (_jsxs("details", { className: "mw-about", children: [_jsxs("summary", { className: "mw-about__summary", children: [_jsx("span", { className: "mw-about__icon", children: "\u2139\uFE0F" }), "About this geocoder"] }), _jsxs("div", { className: "mw-about__body", children: [_jsxs("section", { className: "mw-about__section", children: [_jsx("h3", { className: "mw-about__heading", children: "Neural model" }), _jsxs("p", { children: ["A ~29M-parameter BERT-style encoder classifies each token into one of 33 BIO labels covering 16 address components (street, house number, unit, locality, region, postcode, venue, country, intersection, etc.). It runs entirely in your browser via ", _jsx("strong", { children: "onnxruntime-web" }), " (WebGPU with WASM SIMD fallback). The model ships as a 37.6 MB int8-quantized ONNX bundle; fp32 weights are also available for higher accuracy."] })] }), _jsxs("section", { className: "mw-about__section", children: [_jsx("h3", { className: "mw-about__heading", children: "Confidence colors" }), _jsx("p", { children: "Every classified span carries a confidence score between 0 and 1. The colors in the results table give you a quick visual read:" }), _jsxs("ul", { className: "mw-about__legend", children: [_jsxs("li", { className: "mw-about__item", children: [_jsx("span", { className: "mw-about__swatch mw-about__swatch--high" }), _jsx("strong", { children: "Green" }), " (\u2265 0.8) \u2014 high confidence. The model is nearly certain."] }), _jsxs("li", { className: "mw-about__item", children: [_jsx("span", { className: "mw-about__swatch mw-about__swatch--mid" }), _jsx("strong", { children: "Amber" }), " (0.5\u20130.8) \u2014 moderate confidence. Worth verifying."] }), _jsxs("li", { className: "mw-about__item", children: [_jsx("span", { className: "mw-about__swatch mw-about__swatch--low" }), _jsx("strong", { children: "Red" }), " (< 0.5) \u2014 low confidence. The model is unsure \u2014 likely wrong."] })] }), _jsxs("p", { children: ["These are raw model scores. For calibrated probabilities, the library ships a per-locale isotonic calibrator (", _jsx("code", { children: "calibration.json" }), ") that maps the raw scores to well-calibrated probability estimates."] })] }), _jsxs("section", { className: "mw-about__section", children: [_jsx("h3", { className: "mw-about__heading", children: "WOF resolver" }), _jsxs("p", { children: ["After classification, the resolver queries a ", _jsx("strong", { children: "Who's On First" }), " (WOF) SQLite gazetteer to match the parsed components \u2014 locality, region, and postcode \u2014 against real-world places with coordinates. The cascade tries postcode first (most precise), then locality, then the raw input text. The result is a sorted list of candidate places with WOF IDs, placetypes, lat/lon, and bounding boxes."] })] }), _jsxs("section", { className: "mw-about__section", children: [_jsx("h3", { className: "mw-about__heading", children: "Byte-range gazetteer" }), _jsxs("p", { children: ["The gazetteer is a multi-gigabyte SQLite file served from a public bucket. It loads via", " ", _jsx("strong", { children: "sql.js-httpvfs" }), ", which range-requests only the pages a lookup touches, so your browser fetches a few hundred kilobytes per session instead of the whole file."] })] }), _jsxs("section", { className: "mw-about__section", children: [_jsx("h3", { className: "mw-about__heading", children: "FST prior" }), _jsxs("p", { children: ["A ", _jsx("strong", { children: "finite-state transducer" }), " (FST) built from ~94K US place names runs before the neural classifier. It pre-annotates known locality, region, and postcode spans in the input \u2014 places like \"Springfield\" or \"Cook County\" that the FST can match exactly. These \"FST prior\" hits feed the classifier as strong hints, improving locality and region recall on addresses where the neural model alone might miss them. The FST is active whenever the selected release includes it."] })] })] })] }));
|
|
4
|
+
}
|
|
5
|
+
//# sourceMappingURL=About.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"About.js","sourceRoot":"","sources":["../../lib/common/About.tsx"],"names":[],"mappings":";AAYA,MAAM,UAAU,KAAK;IACpB,OAAO,CACN,mBAAS,SAAS,EAAC,UAAU,aAC5B,mBAAS,SAAS,EAAC,mBAAmB,aACrC,eAAM,SAAS,EAAC,gBAAgB,6BAAU,2BAEjC,EACV,eAAK,SAAS,EAAC,gBAAgB,aAC9B,mBAAS,SAAS,EAAC,mBAAmB,aACrC,aAAI,SAAS,EAAC,mBAAmB,6BAAkB,EACnD,kRAGmC,+CAAgC,wJAE/D,IACK,EAEV,mBAAS,SAAS,EAAC,mBAAmB,aACrC,aAAI,SAAS,EAAC,mBAAmB,kCAAuB,EACxD,0JAGI,EACJ,cAAI,SAAS,EAAC,kBAAkB,aAC/B,cAAI,SAAS,EAAC,gBAAgB,aAC7B,eAAM,SAAS,EAAC,yCAAyC,GAAG,EAC5D,qCAAsB,0EAClB,EACL,cAAI,SAAS,EAAC,gBAAgB,aAC7B,eAAM,SAAS,EAAC,wCAAwC,GAAG,EAC3D,qCAAsB,oEAClB,EACL,cAAI,SAAS,EAAC,gBAAgB,aAC7B,eAAM,SAAS,EAAC,wCAAwC,GAAG,EAC3D,mCAAoB,gFAChB,IACD,EACL,0IAEE,8CAA6B,4EAC3B,IACK,EAEV,mBAAS,SAAS,EAAC,mBAAmB,aACrC,aAAI,SAAS,EAAC,mBAAmB,6BAAkB,EACnD,yEAC8C,8CAAoC,uVAI9E,IACK,EAEV,mBAAS,SAAS,EAAC,mBAAmB,aACrC,aAAI,SAAS,EAAC,mBAAmB,qCAA0B,EAC3D,mHACyF,GAAG,EAC3F,8CAA+B,sJAE5B,IACK,EAEV,mBAAS,SAAS,EAAC,mBAAmB,aACrC,aAAI,SAAS,EAAC,mBAAmB,0BAAe,EAChD,8BACG,uDAAwC,0cAKvC,IACK,IACL,IACG,CACV,CAAA;AACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClientOnly.d.ts","sourceRoot":"","sources":["../../common/ClientOnly.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAwB,MAAM,OAAO,CAAA;AAS5D,MAAM,WAAW,eAAe;IAC/B;;OAEG;IACH,QAAQ,EAAE,MAAM,SAAS,CAAA;IACzB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,wBAAgB,UAAU,CAAC,EAAE,QAAQ,EAAE,QAAe,EAAE,EAAE,eAAe,GAAG,SAAS,CAQpF"}
|
|
1
|
+
{"version":3,"file":"ClientOnly.d.ts","sourceRoot":"","sources":["../../lib/common/ClientOnly.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAwB,MAAM,OAAO,CAAA;AAS5D,MAAM,WAAW,eAAe;IAC/B;;OAEG;IACH,QAAQ,EAAE,MAAM,SAAS,CAAA;IACzB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,wBAAgB,UAAU,CAAC,EAAE,QAAQ,EAAE,QAAe,EAAE,EAAE,eAAe,GAAG,SAAS,CAQpF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClientOnly.js","sourceRoot":"","sources":["../../common/ClientOnly.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAkB,oBAAoB,EAAE,MAAM,OAAO,CAAA;AAE5D;;GAEG;AACH,SAAS,cAAc;IACtB,OAAO,GAAG,EAAE,GAAE,CAAC,CAAA;AAChB,CAAC;AAaD,MAAM,UAAU,UAAU,CAAC,EAAE,QAAQ,EAAE,QAAQ,GAAG,IAAI,EAAmB;IACxE,MAAM,OAAO,GAAG,oBAAoB,CACnC,cAAc,EACd,GAAG,EAAE,CAAC,IAAI,EACV,GAAG,EAAE,CAAC,KAAK,CACX,CAAA;IAED,OAAO,OAAO,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAA;AACvC,CAAC"}
|
|
1
|
+
{"version":3,"file":"ClientOnly.js","sourceRoot":"","sources":["../../lib/common/ClientOnly.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAkB,oBAAoB,EAAE,MAAM,OAAO,CAAA;AAE5D;;GAEG;AACH,SAAS,cAAc;IACtB,OAAO,GAAG,EAAE,GAAE,CAAC,CAAA;AAChB,CAAC;AAaD,MAAM,UAAU,UAAU,CAAC,EAAE,QAAQ,EAAE,QAAQ,GAAG,IAAI,EAAmB;IACxE,MAAM,OAAO,GAAG,oBAAoB,CACnC,cAAc,EACd,GAAG,EAAE,CAAC,IAAI,EACV,GAAG,EAAE,CAAC,KAAK,CACX,CAAA;IAED,OAAO,OAAO,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAA;AACvC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CopyButton.d.ts","sourceRoot":"","sources":["../../common/CopyButton.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAItC,MAAM,WAAW,eAAe;IAC/B;;OAEG;IACH,KAAK,EAAE,MAAM,GAAG,CAAC,MAAM,MAAM,CAAC,CAAA;IAC9B;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB;;OAEG;IACH,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,wBAAgB,UAAU,CAAC,EAC1B,KAAK,EACL,KAAc,EACd,WAAwB,EACxB,SAAoB,EACpB,QAAQ,GACR,EAAE,eAAe,GAAG,SAAS,CAa7B"}
|
|
1
|
+
{"version":3,"file":"CopyButton.d.ts","sourceRoot":"","sources":["../../lib/common/CopyButton.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAItC,MAAM,WAAW,eAAe;IAC/B;;OAEG;IACH,KAAK,EAAE,MAAM,GAAG,CAAC,MAAM,MAAM,CAAC,CAAA;IAC9B;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB;;OAEG;IACH,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,wBAAgB,UAAU,CAAC,EAC1B,KAAK,EACL,KAAc,EACd,WAAwB,EACxB,SAAoB,EACpB,QAAQ,GACR,EAAE,eAAe,GAAG,SAAS,CAa7B"}
|
package/out/common/CopyButton.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useClipboard } from "
|
|
2
|
+
import { useClipboard } from "#common/useClipboard";
|
|
3
3
|
export function CopyButton({ value, label = "Copy", copiedLabel = "✓ Copied", className = "mw-btn", disabled, }) {
|
|
4
4
|
const { copied, copy } = useClipboard();
|
|
5
5
|
return (_jsx("button", { type: "button", className: className, disabled: disabled, onClick: () => copy(typeof value === "function" ? value() : value), children: copied ? copiedLabel : label }));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CopyButton.js","sourceRoot":"","sources":["../../common/CopyButton.tsx"],"names":[],"mappings":";AAWA,OAAO,EAAE,YAAY,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"CopyButton.js","sourceRoot":"","sources":["../../lib/common/CopyButton.tsx"],"names":[],"mappings":";AAWA,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAmBnD,MAAM,UAAU,UAAU,CAAC,EAC1B,KAAK,EACL,KAAK,GAAG,MAAM,EACd,WAAW,GAAG,UAAU,EACxB,SAAS,GAAG,QAAQ,EACpB,QAAQ,GACS;IACjB,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,YAAY,EAAE,CAAA;IAEvC,OAAO,CACN,iBACC,IAAI,EAAC,QAAQ,EACb,SAAS,EAAE,SAAS,EACpB,QAAQ,EAAE,QAAQ,EAClB,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,OAAO,KAAK,KAAK,UAAU,CAAC,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,YAEjE,MAAM,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,GACrB,CACT,CAAA;AACF,CAAC"}
|
|
@@ -8,17 +8,10 @@
|
|
|
8
8
|
* kept structural (`kind: string`) so both the POI query classifier's `QueryKindResult` and the
|
|
9
9
|
* pipeline's projection satisfy it without a hard type dependency.
|
|
10
10
|
*/
|
|
11
|
+
import type { KindView } from "@mailwoman/core/pipeline/client-result";
|
|
11
12
|
import type { ReactNode } from "react";
|
|
12
|
-
export interface KindBadgeResult {
|
|
13
|
-
kind: string;
|
|
14
|
-
confidence: number;
|
|
15
|
-
alternatives: ReadonlyArray<{
|
|
16
|
-
kind: string;
|
|
17
|
-
confidence: number;
|
|
18
|
-
}>;
|
|
19
|
-
}
|
|
20
13
|
export interface KindBadgeProps {
|
|
21
|
-
kindResult:
|
|
14
|
+
kindResult: KindView;
|
|
22
15
|
}
|
|
23
16
|
export declare function KindBadge({ kindResult }: KindBadgeProps): ReactNode;
|
|
24
17
|
//# sourceMappingURL=KindBadge.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KindBadge.d.ts","sourceRoot":"","sources":["../../common/KindBadge.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"KindBadge.d.ts","sourceRoot":"","sources":["../../lib/common/KindBadge.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,wCAAwC,CAAA;AACtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,MAAM,WAAW,cAAc;IAC9B,UAAU,EAAE,QAAQ,CAAA;CACpB;AAID,wBAAgB,SAAS,CAAC,EAAE,UAAU,EAAE,EAAE,cAAc,GAAG,SAAS,CAkBnE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KindBadge.js","sourceRoot":"","sources":["../../common/KindBadge.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"KindBadge.js","sourceRoot":"","sources":["../../lib/common/KindBadge.tsx"],"names":[],"mappings":";AAkBA,MAAM,SAAS,GAAG,CAAC,CAAS,EAAU,EAAE,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,GAAG,CAAC,GAAG,CAAA;AAElE,MAAM,UAAU,SAAS,CAAC,EAAE,UAAU,EAAkB;IACvD,OAAO,CACN,mBAAS,SAAS,EAAC,SAAS,aAC3B,mBAAS,SAAS,EAAC,kBAAkB,aACpC,qCAAsB,OAAC,yBAAO,UAAU,CAAC,IAAI,GAAQ,EAAC,GAAG,EACzD,gBAAM,SAAS,EAAC,qBAAqB,kBAAG,SAAS,CAAC,UAAU,CAAC,UAAU,CAAC,SAAS,IACxE,EACT,UAAU,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,CACjC,aAAI,SAAS,EAAC,uBAAuB,YACnC,UAAU,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CACrC,yBACC,yBAAO,GAAG,CAAC,IAAI,GAAQ,OAAC,gBAAM,SAAS,EAAC,qBAAqB,kBAAG,SAAS,CAAC,GAAG,CAAC,UAAU,CAAC,SAAS,KAD1F,GAAG,CAAC,IAAI,CAEZ,CACL,CAAC,GACE,CACL,CAAC,CAAC,CAAC,IAAI,IACC,CACV,CAAA;AACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LoadingIndicator.d.ts","sourceRoot":"","sources":["../../common/LoadingIndicator.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAMH,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAA;AAExD,MAAM,WAAW,qBAAsB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAClF;;OAEG;IACH,IAAI,CAAC,EAAE,WAAW,CAAA;IAClB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAA;CACnB;AAQD;;GAEG;AACH,eAAO,MAAM,gBAAgB,6DAkB3B,CAAA"}
|
|
1
|
+
{"version":3,"file":"LoadingIndicator.d.ts","sourceRoot":"","sources":["../../lib/common/LoadingIndicator.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAMH,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAA;AAExD,MAAM,WAAW,qBAAsB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAClF;;OAEG;IACH,IAAI,CAAC,EAAE,WAAW,CAAA;IAClB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAA;CACnB;AAQD;;GAEG;AACH,eAAO,MAAM,gBAAgB,6DAkB3B,CAAA"}
|
|
@@ -10,7 +10,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
10
10
|
* component onto plain (`mw-`-prefixed) class names.
|
|
11
11
|
*/
|
|
12
12
|
import { memo } from "react";
|
|
13
|
-
import { cx } from "
|
|
13
|
+
import { cx } from "#common/cx";
|
|
14
14
|
const SIZE_CLASS = {
|
|
15
15
|
small: "mw-spinner--small",
|
|
16
16
|
medium: "",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LoadingIndicator.js","sourceRoot":"","sources":["../../common/LoadingIndicator.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,IAAI,EAAkB,MAAM,OAAO,CAAA;AAE5C,OAAO,EAAE,EAAE,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"LoadingIndicator.js","sourceRoot":"","sources":["../../lib/common/LoadingIndicator.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,IAAI,EAAkB,MAAM,OAAO,CAAA;AAE5C,OAAO,EAAE,EAAE,EAAE,MAAM,YAAY,CAAA;AA+B/B,MAAM,UAAU,GAA+D;IAC9E,KAAK,EAAE,mBAAmB;IAC1B,MAAM,EAAE,EAAE;IACV,KAAK,EAAE,mBAAmB;CAC1B,CAAA;AAED;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,CAAwB,SAAS,gBAAgB,CAAC,EACrF,IAAI,GAAG,SAAS,EAChB,KAAK,EACL,QAAQ,GAAG,CAAC,EACZ,IAAI,GAAG,QAA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,EAAE,aAAa,CAAC,MAAM,CAAC,CAAA;IAC9B,MAAM,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IAC/B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,wBAAgB,WAAW,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAgB,EAAE,QAAQ,EAAE,EAAE,gBAAgB,GAAG,SAAS,CAmBlH"}
|
|
1
|
+
{"version":3,"file":"PresetChips.d.ts","sourceRoot":"","sources":["../../lib/common/PresetChips.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,MAAM,WAAW,MAAM;IACtB,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;CAChB;AAED,MAAM,WAAW,gBAAgB;IAChC,OAAO,EAAE,aAAa,CAAC,MAAM,CAAC,CAAA;IAC9B,MAAM,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IAC/B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,wBAAgB,WAAW,CAAC,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAgB,EAAE,QAAQ,EAAE,EAAE,gBAAgB,GAAG,SAAS,CAmBlH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PresetChips.js","sourceRoot":"","sources":["../../common/PresetChips.tsx"],"names":[],"mappings":";AAqCA,MAAM,UAAU,WAAW,CAAC,EAAE,OAAO,EA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software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
* @file Confidence banding shared by every component that colours a span by confidence.
|
|
6
|
+
*
|
|
7
|
+
* It is a presentation choice, not a model one: the parser emits a continuous confidence and these
|
|
8
|
+
* bounds only decide which colour a span is drawn in, so they live here rather than anywhere the
|
|
9
|
+
* pipeline can see them.
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* At or above this the span is drawn as high-confidence.
|
|
13
|
+
*/
|
|
14
|
+
export declare const HIGH_CONFIDENCE_MIN = 0.8;
|
|
15
|
+
/**
|
|
16
|
+
* At or above this the span is drawn as medium-confidence; below it, low.
|
|
17
|
+
*/
|
|
18
|
+
export declare const MID_CONFIDENCE_MIN = 0.5;
|
|
19
|
+
/**
|
|
20
|
+
* The banding a component applies to a span's confidence.
|
|
21
|
+
*/
|
|
22
|
+
export type ConfidenceTier = "high" | "mid" | "low";
|
|
23
|
+
/**
|
|
24
|
+
* Bands a continuous confidence into the three tiers the demo styles against.
|
|
25
|
+
*
|
|
26
|
+
* @param confidence A parser confidence in `[0, 1]`.
|
|
27
|
+
*
|
|
28
|
+
* @returns The tier to style with.
|
|
29
|
+
*/
|
|
30
|
+
export declare function confidenceTier(confidence: number): ConfidenceTier;
|
|
31
|
+
/**
|
|
32
|
+
* {@link confidenceTier} for a possibly-absent confidence: an unmeasured span is drawn as `mid` rather than `low`, so an
|
|
33
|
+
* older model that emits no confidence never reads as uniformly wrong.
|
|
34
|
+
*/
|
|
35
|
+
export declare function confidenceTierOrMid(confidence?: number): ConfidenceTier;
|
|
36
|
+
//# sourceMappingURL=confidence-tiers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"confidence-tiers.d.ts","sourceRoot":"","sources":["../../lib/common/confidence-tiers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH;;GAEG;AACH,eAAO,MAAM,mBAAmB,MAAM,CAAA;AAEtC;;GAEG;AACH,eAAO,MAAM,kBAAkB,MAAM,CAAA;AAErC;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,KAAK,GAAG,KAAK,CAAA;AAEnD;;;;;;GAMG;AACH,wBAAgB,cAAc,CAAC,UAAU,EAAE,MAAM,GAAG,cAAc,CAMjE;AAED;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,cAAc,CAIvE"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
* @file Confidence banding shared by every component that colours a span by confidence.
|
|
6
|
+
*
|
|
7
|
+
* It is a presentation choice, not a model one: the parser emits a continuous confidence and these
|
|
8
|
+
* bounds only decide which colour a span is drawn in, so they live here rather than anywhere the
|
|
9
|
+
* pipeline can see them.
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* At or above this the span is drawn as high-confidence.
|
|
13
|
+
*/
|
|
14
|
+
export const HIGH_CONFIDENCE_MIN = 0.8;
|
|
15
|
+
/**
|
|
16
|
+
* At or above this the span is drawn as medium-confidence; below it, low.
|
|
17
|
+
*/
|
|
18
|
+
export const MID_CONFIDENCE_MIN = 0.5;
|
|
19
|
+
/**
|
|
20
|
+
* Bands a continuous confidence into the three tiers the demo styles against.
|
|
21
|
+
*
|
|
22
|
+
* @param confidence A parser confidence in `[0, 1]`.
|
|
23
|
+
*
|
|
24
|
+
* @returns The tier to style with.
|
|
25
|
+
*/
|
|
26
|
+
export function confidenceTier(confidence) {
|
|
27
|
+
if (confidence >= HIGH_CONFIDENCE_MIN)
|
|
28
|
+
return "high";
|
|
29
|
+
if (confidence >= MID_CONFIDENCE_MIN)
|
|
30
|
+
return "mid";
|
|
31
|
+
return "low";
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* {@link confidenceTier} for a possibly-absent confidence: an unmeasured span is drawn as `mid` rather than `low`, so an
|
|
35
|
+
* older model that emits no confidence never reads as uniformly wrong.
|
|
36
|
+
*/
|
|
37
|
+
export function confidenceTierOrMid(confidence) {
|
|
38
|
+
if (confidence == null)
|
|
39
|
+
return "mid";
|
|
40
|
+
return confidenceTier(confidence);
|
|
41
|
+
}
|
|
42
|
+
//# sourceMappingURL=confidence-tiers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"confidence-tiers.js","sourceRoot":"","sources":["../../lib/common/confidence-tiers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH;;GAEG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,GAAG,CAAA;AAEtC;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,GAAG,CAAA;AAOrC;;;;;;GAMG;AACH,MAAM,UAAU,cAAc,CAAC,UAAkB;IAChD,IAAI,UAAU,IAAI,mBAAmB;QAAE,OAAO,MAAM,CAAA;IAEpD,IAAI,UAAU,IAAI,kBAAkB;QAAE,OAAO,KAAK,CAAA;IAElD,OAAO,KAAK,CAAA;AACb,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,mBAAmB,CAAC,UAAmB;IACtD,IAAI,UAAU,IAAI,IAAI;QAAE,OAAO,KAAK,CAAA;IAEpC,OAAO,cAAc,CAAC,UAAU,CAAC,CAAA;AAClC,CAAC"}
|
package/out/common/cx.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cx.d.ts","sourceRoot":"","sources":["../../common/cx.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;AAE7F;;GAEG;AACH,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAoBlD"}
|
|
1
|
+
{"version":3,"file":"cx.d.ts","sourceRoot":"","sources":["../../lib/common/cx.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;AAE7F;;GAEG;AACH,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAoBlD"}
|
package/out/common/cx.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cx.js","sourceRoot":"","sources":["../../common/cx.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH;;GAEG;AACH,MAAM,UAAU,EAAE,CAAC,GAAG,MAAoB;IACzC,MAAM,GAAG,GAAa,EAAE,CAAA;IAExB,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;QAC5B,IAAI,CAAC,KAAK;YAAE,SAAQ;QAEpB,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC5D,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAA;YAEvB,SAAQ;QACT,CAAC;QAED,KAAK,MAAM,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;YAC/C,IAAI,EAAE,EAAE,CAAC;gBACR,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA;YACd,CAAC;QACF,CAAC;IACF,CAAC;IAED,OAAO,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA;AACrB,CAAC"}
|
|
1
|
+
{"version":3,"file":"cx.js","sourceRoot":"","sources":["../../lib/common/cx.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH;;GAEG;AACH,MAAM,UAAU,EAAE,CAAC,GAAG,MAAoB;IACzC,MAAM,GAAG,GAAa,EAAE,CAAA;IAExB,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;QAC5B,IAAI,CAAC,KAAK;YAAE,SAAQ;QAEpB,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC5D,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAA;YAEvB,SAAQ;QACT,CAAC;QAED,KAAK,MAAM,CAAC,GAAG,EAAE,EAAE,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;YAC/C,IAAI,EAAE,EAAE,CAAC;gBACR,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA;YACd,CAAC;QACF,CAAC;IACF,CAAC;IAED,OAAO,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA;AACrB,CAAC"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
* @file Word tokenization + span ownership shared by the word-level visualizers.
|
|
6
|
+
*
|
|
7
|
+
* A word-level panel splits the raw input on whitespace and assigns each word to its most specific
|
|
8
|
+
* covering span (the shortest-span owner, the same rule a character-level highlight applies per
|
|
9
|
+
* character). Two panels must agree for the BIO labels to line up between them, so the split and
|
|
10
|
+
* the owner walk live here.
|
|
11
|
+
*/
|
|
12
|
+
export interface WordToken {
|
|
13
|
+
/**
|
|
14
|
+
* The word text as it appears in the input.
|
|
15
|
+
*/
|
|
16
|
+
text: string;
|
|
17
|
+
/**
|
|
18
|
+
* Leading whitespace before this word.
|
|
19
|
+
*/
|
|
20
|
+
whitespace: string;
|
|
21
|
+
/**
|
|
22
|
+
* Start offset in the input string.
|
|
23
|
+
*/
|
|
24
|
+
start: number;
|
|
25
|
+
/**
|
|
26
|
+
* End offset in the input string (exclusive).
|
|
27
|
+
*/
|
|
28
|
+
end: number;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Tokenize the raw input into words, preserving leading whitespace for each token.
|
|
32
|
+
*/
|
|
33
|
+
export declare function tokenizeWords(input: string): WordToken[];
|
|
34
|
+
/**
|
|
35
|
+
* A half-open `[start, end)` character range into the input.
|
|
36
|
+
*/
|
|
37
|
+
export interface CharSpan {
|
|
38
|
+
start: number;
|
|
39
|
+
end: number;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Per-word index of the most specific (shortest) span covering it, or `-1` when no span overlaps the word. A word is
|
|
43
|
+
* covered when any part of it falls within the span.
|
|
44
|
+
*/
|
|
45
|
+
export declare function shortestSpanOwners(words: readonly CharSpan[], spans: readonly CharSpan[]): number[];
|
|
46
|
+
//# sourceMappingURL=text-tokens.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-tokens.d.ts","sourceRoot":"","sources":["../../lib/common/text-tokens.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,MAAM,WAAW,SAAS;IACzB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,UAAU,EAAE,MAAM,CAAA;IAClB;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;IACb;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;CACX;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,EAAE,CAyBxD;AAED;;GAEG;AACH,MAAM,WAAW,QAAQ;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,GAAG,EAAE,MAAM,CAAA;CACX;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,SAAS,QAAQ,EAAE,EAAE,KAAK,EAAE,SAAS,QAAQ,EAAE,GAAG,MAAM,EAAE,CAcnG"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
* @file Word tokenization + span ownership shared by the word-level visualizers.
|
|
6
|
+
*
|
|
7
|
+
* A word-level panel splits the raw input on whitespace and assigns each word to its most specific
|
|
8
|
+
* covering span (the shortest-span owner, the same rule a character-level highlight applies per
|
|
9
|
+
* character). Two panels must agree for the BIO labels to line up between them, so the split and
|
|
10
|
+
* the owner walk live here.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* Tokenize the raw input into words, preserving leading whitespace for each token.
|
|
14
|
+
*/
|
|
15
|
+
export function tokenizeWords(input) {
|
|
16
|
+
const words = [];
|
|
17
|
+
let i = 0;
|
|
18
|
+
// `charAt` answers "" past the end, which no whitespace test matches, so both walks stop at the input's length.
|
|
19
|
+
while (i < input.length) {
|
|
20
|
+
let ws = "";
|
|
21
|
+
while (/\s/.test(input.charAt(i))) {
|
|
22
|
+
ws += input.charAt(i);
|
|
23
|
+
i++;
|
|
24
|
+
}
|
|
25
|
+
if (i >= input.length)
|
|
26
|
+
break;
|
|
27
|
+
const start = i;
|
|
28
|
+
while (i < input.length && !/\s/.test(input.charAt(i))) {
|
|
29
|
+
i++;
|
|
30
|
+
}
|
|
31
|
+
words.push({ text: input.slice(start, i), start, end: i, whitespace: ws });
|
|
32
|
+
}
|
|
33
|
+
return words;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Per-word index of the most specific (shortest) span covering it, or `-1` when no span overlaps the word. A word is
|
|
37
|
+
* covered when any part of it falls within the span.
|
|
38
|
+
*/
|
|
39
|
+
export function shortestSpanOwners(words, spans) {
|
|
40
|
+
return words.map((word) => {
|
|
41
|
+
let best = -1;
|
|
42
|
+
let bestLen = Infinity;
|
|
43
|
+
for (const [s, sp] of spans.entries()) {
|
|
44
|
+
if (word.start < sp.end && word.end > sp.start && sp.end - sp.start < bestLen) {
|
|
45
|
+
bestLen = sp.end - sp.start;
|
|
46
|
+
best = s;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
return best;
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=text-tokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-tokens.js","sourceRoot":"","sources":["../../lib/common/text-tokens.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAqBH;;GAEG;AACH,MAAM,UAAU,aAAa,CAAC,KAAa;IAC1C,MAAM,KAAK,GAAgB,EAAE,CAAA;IAC7B,IAAI,CAAC,GAAG,CAAC,CAAA;IAET,gHAAgH;IAChH,OAAO,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC;QACzB,IAAI,EAAE,GAAG,EAAE,CAAA;QAEX,OAAO,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;YACnC,EAAE,IAAI,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAA;YAErB,CAAC,EAAE,CAAA;QACJ,CAAC;QAED,IAAI,CAAC,IAAI,KAAK,CAAC,MAAM;YAAE,MAAK;QAC5B,MAAM,KAAK,GAAG,CAAC,CAAA;QAEf,OAAO,CAAC,GAAG,KAAK,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;YACxD,CAAC,EAAE,CAAA;QACJ,CAAC;QAED,KAAK,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,UAAU,EAAE,EAAE,EAAE,CAAC,CAAA;IAC3E,CAAC;IAED,OAAO,KAAK,CAAA;AACb,CAAC;AAUD;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAAC,KAA0B,EAAE,KAA0B;IACxF,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;QACzB,IAAI,IAAI,GAAG,CAAC,CAAC,CAAA;QACb,IAAI,OAAO,GAAG,QAAQ,CAAA;QAEtB,KAAK,MAAM,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,KAAK,CAAC,OAAO,EAAE,EAAE,CAAC;YACvC,IAAI,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC,GAAG,IAAI,IAAI,CAAC,GAAG,GAAG,EAAE,CAAC,KAAK,IAAI,EAAE,CAAC,GAAG,GAAG,EAAE,CAAC,KAAK,GAAG,OAAO,EAAE,CAAC;gBAC/E,OAAO,GAAG,EAAE,CAAC,GAAG,GAAG,EAAE,CAAC,KAAK,CAAA;gBAC3B,IAAI,GAAG,CAAC,CAAA;YACT,CAAC;QACF,CAAC;QAED,OAAO,IAAI,CAAA;IACZ,CAAC,CAAC,CAAA;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useClipboard.d.ts","sourceRoot":"","sources":["../../common/useClipboard.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAgCH,MAAM,WAAW,YAAY;IAC5B,MAAM,EAAE,OAAO,CAAA;IACf,IAAI,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;CACtC;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,OAAO,SAAO,GAAG,YAAY,CA6BzD"}
|
|
1
|
+
{"version":3,"file":"useClipboard.d.ts","sourceRoot":"","sources":["../../lib/common/useClipboard.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAgCH,MAAM,WAAW,YAAY;IAC5B,MAAM,EAAE,OAAO,CAAA;IACf,IAAI,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;CACtC;AAED;;GAEG;AACH,wBAAgB,YAAY,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
{"version":3,"file":"useDebouncedValue.d.ts","sourceRoot":"","sources":["../../common/useDebouncedValue.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC,CAUjE"}
|
|
1
|
+
{"version":3,"file":"useDebouncedValue.d.ts","sourceRoot":"","sources":["../../lib/common/useDebouncedValue.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,MAAM,GAAG,CAAC,CAUjE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useDebouncedValue.js","sourceRoot":"","sources":["../../common/useDebouncedValue.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAE3C,MAAM,UAAU,iBAAiB,CAAI,KAAQ,EAAE,OAAe;IAC7D,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;IAEjD,SAAS,CAAC,GAAG,EAAE;QACd,MAAM,EAAE,GAAG,UAAU,CAAC,GAAG,EAAE,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC,CAAA;QAEzD,OAAO,GAAG,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC,CAAA;IAC9B,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,CAAA;IAEpB,OAAO,SAAS,CAAA;AACjB,CAAC"}
|
|
1
|
+
{"version":3,"file":"useDebouncedValue.js","sourceRoot":"","sources":["../../lib/common/useDebouncedValue.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAE3C,MAAM,UAAU,iBAAiB,CAAI,KAAQ,EAAE,OAAe;IAC7D,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAA;IAEjD,SAAS,CAAC,GAAG,EAAE;QACd,MAAM,EAAE,GAAG,UAAU,CAAC,GAAG,EAAE,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC,CAAA;QAEzD,OAAO,GAAG,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC,CAAA;IAC9B,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,CAAA;IAEpB,OAAO,SAAS,CAAA;AACjB,CAAC"}
|
package/out/index.d.ts
CHANGED
|
@@ -19,17 +19,17 @@ export { ClientOnly } from "./common/ClientOnly.tsx";
|
|
|
19
19
|
export type { ClientOnlyProps } from "./common/ClientOnly.tsx";
|
|
20
20
|
export { CopyButton } from "./common/CopyButton.tsx";
|
|
21
21
|
export type { CopyButtonProps } from "./common/CopyButton.tsx";
|
|
22
|
-
export { cx } from "
|
|
23
|
-
export type { ClassValue } from "
|
|
22
|
+
export { cx } from "#common/cx";
|
|
23
|
+
export type { ClassValue } from "#common/cx";
|
|
24
24
|
export { KindBadge } from "./common/KindBadge.tsx";
|
|
25
|
-
export type { KindBadgeProps
|
|
25
|
+
export type { KindBadgeProps } from "./common/KindBadge.tsx";
|
|
26
26
|
export { LoadingIndicator } from "./common/LoadingIndicator.tsx";
|
|
27
27
|
export type { LoadingIndicatorProps, LoadingMode } from "./common/LoadingIndicator.tsx";
|
|
28
28
|
export { PresetChips } from "./common/PresetChips.tsx";
|
|
29
29
|
export type { Preset, PresetChipsProps } from "./common/PresetChips.tsx";
|
|
30
|
-
export { useClipboard } from "
|
|
31
|
-
export type { UseClipboard } from "
|
|
32
|
-
export { useDebouncedValue } from "
|
|
30
|
+
export { useClipboard } from "#common/useClipboard";
|
|
31
|
+
export type { UseClipboard } from "#common/useClipboard";
|
|
32
|
+
export { useDebouncedValue } from "#common/useDebouncedValue";
|
|
33
33
|
export { AbstainPanel } from "./poi/AbstainPanel.tsx";
|
|
34
34
|
export type { AbstainPanelProps } from "./poi/AbstainPanel.tsx";
|
|
35
35
|
export { LiveResultsBlock } from "./poi/LiveResultsBlock.tsx";
|
|
@@ -40,30 +40,39 @@ export { POIExplorer } from "./poi/POIExplorer.tsx";
|
|
|
40
40
|
export type { POIExplorerProps } from "./poi/POIExplorer.tsx";
|
|
41
41
|
export { QueryInput } from "./poi/QueryInput.tsx";
|
|
42
42
|
export type { QueryInputProps } from "./poi/QueryInput.tsx";
|
|
43
|
-
export { formatDistance, loadPOIRuntime, POI_DEFAULT_TEXT, POI_PRESETS } from "
|
|
43
|
+
export { formatDistance, loadPOIRuntime, POI_DEFAULT_TEXT, POI_PRESETS } from "#poi/runtime";
|
|
44
44
|
export { SubjectPanel } from "./poi/SubjectPanel.tsx";
|
|
45
45
|
export type { SubjectPanelProps } from "./poi/SubjectPanel.tsx";
|
|
46
|
-
export type { CategoryRecord, LiveSearchState, LoadPOIRuntime, POIBrandSubject, POICategorySubject, POIExplorerResult, POILiveSearch, POILiveSearchResult, POIRuntime, POISearchHit, POISubject, POISubjectBase, TaxonomyLookup, } from "
|
|
47
|
-
export { usePOISearch } from "
|
|
48
|
-
export type { UsePOISearch, UsePOISearchOptions } from "
|
|
46
|
+
export type { CategoryRecord, LiveSearchState, LoadPOIRuntime, POIBrandSubject, POICategorySubject, POIExplorerResult, POILiveSearch, POILiveSearchResult, POIRuntime, POISearchHit, POISubject, POISubjectBase, TaxonomyLookup, } from "#poi/types";
|
|
47
|
+
export { usePOISearch } from "#poi/usePOISearch";
|
|
48
|
+
export type { UsePOISearch, UsePOISearchOptions } from "#poi/usePOISearch";
|
|
49
|
+
export { About } from "./common/About.tsx";
|
|
50
|
+
export { FailureDiagnostic } from "./pipeline/FailureDiagnostic.tsx";
|
|
51
|
+
export type { FailureDiagnosticProps } from "./pipeline/FailureDiagnostic.tsx";
|
|
52
|
+
export { SpanHighlight } from "./pipeline/SpanHighlight.tsx";
|
|
53
|
+
export type { SpanHighlightProps } from "./pipeline/SpanHighlight.tsx";
|
|
54
|
+
export { TimingPanel } from "./pipeline/TimingPanel.tsx";
|
|
55
|
+
export type { TimingPanelProps } from "./pipeline/TimingPanel.tsx";
|
|
56
|
+
export { TreeView } from "./pipeline/TreeView.tsx";
|
|
57
|
+
export type { TreeViewProps } from "./pipeline/TreeView.tsx";
|
|
49
58
|
export { CandidatePicker } from "./pipeline/CandidatePicker.tsx";
|
|
50
59
|
export type { CandidatePickerProps } from "./pipeline/CandidatePicker.tsx";
|
|
51
60
|
export { ComponentTable } from "./pipeline/ComponentTable.tsx";
|
|
52
61
|
export type { ComponentTableProps } from "./pipeline/ComponentTable.tsx";
|
|
53
62
|
export { ConfidenceCell } from "./pipeline/ConfidenceCell.tsx";
|
|
54
63
|
export type { ConfidenceCellProps } from "./pipeline/ConfidenceCell.tsx";
|
|
55
|
-
export { buildParsePayload } from "
|
|
56
|
-
export { PIPELINE_DEFAULT_ADDRESS, PIPELINE_PRESETS } from "
|
|
64
|
+
export { buildParsePayload } from "#pipeline/copy";
|
|
65
|
+
export { PIPELINE_DEFAULT_ADDRESS, PIPELINE_PRESETS } from "#pipeline/presets";
|
|
57
66
|
export { PipelineExplorer } from "./pipeline/PipelineExplorer.tsx";
|
|
58
67
|
export type { PipelineExplorerProps } from "./pipeline/PipelineExplorer.tsx";
|
|
59
68
|
export { QueryForm } from "./pipeline/QueryForm.tsx";
|
|
60
69
|
export type { QueryFormProps } from "./pipeline/QueryForm.tsx";
|
|
61
70
|
export { ResolvedPlace } from "./pipeline/ResolvedPlace.tsx";
|
|
62
71
|
export type { ResolvedPlaceProps } from "./pipeline/ResolvedPlace.tsx";
|
|
63
|
-
export type {
|
|
64
|
-
export { useParsePipeline } from "
|
|
65
|
-
export type { UseParsePipeline, UseParsePipelineOptions } from "
|
|
66
|
-
export {
|
|
67
|
-
export type {
|
|
68
|
-
export type {
|
|
72
|
+
export type { PipelineLoadingState, PipelinePanels, PipelineRuntime } from "#pipeline/types";
|
|
73
|
+
export { useParsePipeline } from "#pipeline/useParsePipeline";
|
|
74
|
+
export type { UseParsePipeline, UseParsePipelineOptions } from "#pipeline/useParsePipeline";
|
|
75
|
+
export { useReleaseRuntime } from "#runtime/useReleaseRuntime";
|
|
76
|
+
export type { AssetsLoadContext, ReleaseBase, ReleaseLoaderState, ReleaseManifest, ReleaseRuntimeConfig, } from "#runtime/useReleaseRuntime";
|
|
77
|
+
export type { GeocoderRuntime, InferenceBackend, LngLatTuple, MapBias, MapCanvasExtraProps, MapCanvasProps, MapCanvasStyle, OverlaySpec, Suggestion, VersionOption, } from "#map/index";
|
|
69
78
|
//# sourceMappingURL=index.d.ts.map
|