@chrtco/sdk 0.10.7 → 0.10.8
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 +16 -0
- package/dist/index.cjs +500 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +51 -2
- package/dist/index.d.ts +51 -2
- package/dist/index.js +498 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1380,6 +1380,25 @@ interface StyleUrlOptions {
|
|
|
1380
1380
|
* `CHRT_STYLE_MODES`). The served document echoes the resolved mode in
|
|
1381
1381
|
* `metadata["chrt:render-mode"]` and the `X-Style-Mode` header. */
|
|
1382
1382
|
mode?: ChrtStyleMode;
|
|
1383
|
+
/** Draw the CHRTland land base under the chart (default off). Adds the
|
|
1384
|
+
* `CHRT_LAND` source and a dozen `chrtland-*` layers, all beneath every
|
|
1385
|
+
* S-57 class so land can never occlude a portrayal.
|
|
1386
|
+
*
|
|
1387
|
+
* **CHRTland is not chart data and does not come from a hydrographic
|
|
1388
|
+
* office** — never present its shoreline to a mariner as charted.
|
|
1389
|
+
*
|
|
1390
|
+
* Needs `CHRT_LAND` on the tile token, which follows the chart sources
|
|
1391
|
+
* your key holds; without it the style request is a 403
|
|
1392
|
+
* `region_not_licensed` rather than a document with dead sources. */
|
|
1393
|
+
land?: boolean;
|
|
1394
|
+
/** Add CHRTland's terrarium hillshade (default off). Separately opt-in
|
|
1395
|
+
* from {@link land} and requires it — `relief` alone is a 400
|
|
1396
|
+
* `relief_requires_land`.
|
|
1397
|
+
*
|
|
1398
|
+
* It also needs a `CHRT_RELIEF` grant that no chart source issues yet,
|
|
1399
|
+
* so this currently returns 403 for every key. It will start working
|
|
1400
|
+
* with no SDK change once that grant ships. */
|
|
1401
|
+
relief?: boolean;
|
|
1383
1402
|
}
|
|
1384
1403
|
interface FetchStyleOptions extends StyleUrlOptions {
|
|
1385
1404
|
signal?: AbortSignal;
|
|
@@ -2989,7 +3008,26 @@ interface PmtilesVectorSource {
|
|
|
2989
3008
|
minzoom: number;
|
|
2990
3009
|
maxzoom: number;
|
|
2991
3010
|
}
|
|
3011
|
+
/**
|
|
3012
|
+
* Terrarium elevation, served as PNG from `CHRT_RELIEF`. Separate from the
|
|
3013
|
+
* vector shapes because MapLibre needs `type: "raster-dem"` and an explicit
|
|
3014
|
+
* `encoding` — a raster-dem source read as a plain raster renders the encoded
|
|
3015
|
+
* RGB as a garish false-colour image rather than as elevation.
|
|
3016
|
+
*/
|
|
3017
|
+
interface RasterDemSource {
|
|
3018
|
+
type: "raster-dem";
|
|
3019
|
+
tiles: string[];
|
|
3020
|
+
encoding: "terrarium";
|
|
3021
|
+
tileSize: number;
|
|
3022
|
+
minzoom: number;
|
|
3023
|
+
maxzoom: number;
|
|
3024
|
+
}
|
|
2992
3025
|
type VectorSourceSpec = MapboxVectorSource | PmtilesVectorSource;
|
|
3026
|
+
type AnySourceSpec = VectorSourceSpec | RasterDemSource;
|
|
3027
|
+
/** CHRTland's vector land base. ADR 0023: its own archive, never chart data. */
|
|
3028
|
+
declare const LAND_REGION = "CHRT_LAND";
|
|
3029
|
+
/** CHRTland's terrarium relief. */
|
|
3030
|
+
declare const RELIEF_REGION = "CHRT_RELIEF";
|
|
2993
3031
|
type SourceMode = "mapbox" | "pmtiles";
|
|
2994
3032
|
/** Canonical source id used in `generateStyle()` — matches the region name
|
|
2995
3033
|
* of the one consolidated PMTiles served by the tile-worker for this region. */
|
|
@@ -3006,6 +3044,17 @@ interface BuildSourcesOptions {
|
|
|
3006
3044
|
buildTag?: string;
|
|
3007
3045
|
/** Override tile-worker origin (e.g. staging). Default: DEFAULT_TILE_BASE_URL. */
|
|
3008
3046
|
tileBaseUrl?: string;
|
|
3047
|
+
/**
|
|
3048
|
+
* Emit the CHRTland vector land base as a second source (ADR 0023). Off by
|
|
3049
|
+
* default: it costs a source, and the region must be granted on the token.
|
|
3050
|
+
*/
|
|
3051
|
+
land?: boolean;
|
|
3052
|
+
/**
|
|
3053
|
+
* Emit CHRTland's terrarium relief as a raster-dem source. Separate from
|
|
3054
|
+
* `land` because relief needs a raster-capable worker AND a grant that
|
|
3055
|
+
* `land-regions.ts` still withholds.
|
|
3056
|
+
*/
|
|
3057
|
+
relief?: boolean;
|
|
3009
3058
|
}
|
|
3010
3059
|
/**
|
|
3011
3060
|
* Build the "sources" block for a CHRT style.
|
|
@@ -3015,7 +3064,7 @@ interface BuildSourcesOptions {
|
|
|
3015
3064
|
* routed by the Worker to the one consolidated PMTiles:
|
|
3016
3065
|
* `${tileBaseUrl}/v1/tiles/{region}/{z}/{x}/{y}.mvt`
|
|
3017
3066
|
*/
|
|
3018
|
-
declare function buildSources(opts?: BuildSourcesOptions): Record<string,
|
|
3067
|
+
declare function buildSources(opts?: BuildSourcesOptions): Record<string, AnySourceSpec>;
|
|
3019
3068
|
|
|
3020
3069
|
/**
|
|
3021
3070
|
* Builds Mapbox GL Style layer specs from S-52 lookup entries.
|
|
@@ -4256,4 +4305,4 @@ declare class Chrt {
|
|
|
4256
4305
|
warmTiles(region?: string): Promise<void>;
|
|
4257
4306
|
}
|
|
4258
4307
|
|
|
4259
|
-
export { ALL_NAV_AID_LAYERS, ALL_WATER_BODY_LAYERS, AREA_QUERY_LAYERS, ATON_EXPRESSION_CLASSES, type AheadCoverageCell, type AheadFeatureProperties, type AheadOptions, type AheadResponse, type AlongRouteFeatureProperties, type AlongRouteOptions, type AlongRouteResponse, type AreaInspectResult, type AtlasStyle, type AttachOptions, BAND_DRAW_ORDER, BAND_PRIORITY_RANGES, type BBox, BRIDGE_QUERY_LAYERS, BUILD_MAXZOOM, BUILD_MINZOOM, type BandCode, type BandPriorityRange, type BridgeInspectResult, type BuildOfflineStyleOptions, type BuildSourcesOptions, CHART_BAND_CODES, CHART_CASCADE_CODES, CHART_SECTIONS, CHRTRASTER_REF_CROPS, CHRTRASTER_SVGS, CHRT_ATON_COLORS, CHRT_GLYPH_NAMES, CHRT_GLYPH_SVGS, CHRT_ICON_EXPRESSIONS, CHRT_ICON_PREFIX, CHRT_SDF_GLYPHS, CHRT_STYLE_MODES, type CandidateQueryOptions, type CandidatesEventContext, type CellDeletedEvent, type CellDetail, type CellEventData, type CellNewEvent, type CellUpdatedData, type CellUpdatedEvent, type CellsOptions, type CellsResponse, type ChartSection, Chrt, type ChrtConfig, ChrtError, type ChrtStyleMode, type ChrtStyleOptions, type ChrtStyleTheme, type ChrtSymbolSet, type ClickAnchor, ColorTableName, type CoverageOptions, type CoverageResponse, type CoverageRouteCell, type CoverageRouteOptions, type CoverageRouteResponse, type CoverageSource, type CustomStyleConfig, DEFAULT_CLICK_TOLERANCE, DEFAULT_CUSTOM_STYLE_CONFIG, DEFAULT_INSPECT_CLASS_RANK, DEFAULT_LABEL_SETTINGS, DEFAULT_NAV_AID_SETTINGS, DEFAULT_REGION, DEFAULT_SAFETY_CONTOUR_M, DEFAULT_SOUNDING_SETTINGS, DEFAULT_TILE_BASE_URL, DEFAULT_TILE_REGION, DEFAULT_WATER_BODY_SETTINGS, type DecodedAreaFeature, type DecodedBridge, type DecodedNavAid, type DecodedProperty, type DisplayCategory, type DisplayMode, type FeatureCollection, type FeaturesOptions, type FetchStyleOptions, FileSystemAdapter, type FlashPattern, type FlashPhase, type GenerateCustomStyleOptions, type GeneratedCustomStyle, type GeoJsonFeature, type GeoJsonGeometry, type GeomType, INSPECT_CLASS_RANK, INSPECT_RANK_DEVIATIONS, type InspectCandidate, type InspectCandidateSet, type InspectEnrichment, type InspectEventContext, type InspectNotice, type InspectOptions, type InspectResult, type InspectTargetClass, type InspectableFeature, InteractClient, type InteractEntitlement, InteractError, type InteractErrorCode, type InteractHandle, type InteractMapLike, type InteractMapMouseEvent, LABELED_LAYERS, LABEL_BEHAVIOR, LABEL_LAYER_GROUPS, LABEL_PRIORITY, type LabelBehavior, type LabelConfigOptions, type LabelLayerConfig, type LabelSettings, type LookupEntry, type MapLibreStyle, type MapboxStyle, type MapboxVectorSource, type MarineAlert, type MarineAlertsOptions, type MarineAlertsResponse, type MarineConditionsOptions, type MarineConditionsResponse, type MarineForecastOptions, type MarineForecastPeriod, type MarineForecastResponse, type MarineSeas, type MarineStation, type MarineSwellTrain, type MarineWind, type MarineZoneRef, NAUTICAL_SYMBOLS, NAV_AID_LAYER_GROUPS, NAV_AID_QUERY_LAYERS, NON_SOLAS_DISCLAIMER, NON_SOLAS_DISCLAIMER_SHORT, type NauticalCategory, type NauticalSymbol, type NavAidInspectResult, type NavAidSettings, type NearbyMarineStation, type OfflineBundleResponse, type OfflineDownloadOptions, type OfflineDownloadProgress, type OfflineDownloadResult, OfflineError, type OfflineErrorCode, type OfflineFetchStyleOptions, type OfflineHeartbeatOptions, type OfflineRegionSummary, type OfflineRemoveOptions, OfflineStyleError, type OfflineStylePlatform, type OfflineStyleResponse, type PmtilesVectorSource, type QueryFeatureProperties, type QueryOptions, type QueryResponse, RASTER_ATON_CLASSES, RASTER_GLYPH_NAMES, RASTER_ICON_PREFIX, type ResolvedStyle, type ResolvedTheme, type S101ArtworkProvenance, type S101Feature, S101_AREA_FILL_NAMES, S101_CHART_SECTIONS, S101_FEATURES, S101_ICON_PREFIX, S101_LINE_STYLE_NAMES, S101_NEW_SYMBOLS, S101_NO_OFFICIAL_COUNTERPART, S101_SOURCE_COMMIT, S101_SYMBOL_GROUPS, S101_SYMBOL_NAMES, S52_ATON_LOOKUPS, S52_ATON_LOOKUPS_PAPER, S52_DRAW_ORDER, S52_LOOKUP, S52_PATTERN_SPRITE_PREFIX, SOUNDING_LAYERS, SYMBOL_FAMILIES, SYMBOL_FAMILY_META, SYMBOL_GROUPS, SYMBOL_MAP, type ScaleBand, type SearchCoverageNotice, type SearchHit, type SearchOptions, type SearchResponse, type SectorArcFeature, type SectorArcFeatureCollection, type SectorInfo, type SoundingSettings, type SourceMode, type StyleGeneratorOptions, type StyleLayer, type StyleUrlOptions, type SymbolFamily, type SymbolFamilyMeta, type SymbolGroup, TileAuth, type TileGroup, type TileGroupsResponse, TileTokenError, type TileTokenErrorCode, type TileTokenResponse, type TransformRequest, type TransformedRequest, type VectorSourceSpec, type VesselProfile, WATER_BODY_LAYER_GROUPS, type WaterBodySettings, WeatherEndpoint, type WeatherReading, type WebhookEvent, type WebhookEventType, type WebhookPayload, applyChrtSymbolSet, applyColorTheme, applyCustomStyleSettings, applyRasterSymbolSet, applyS101SymbolSet, atonIconExpression, bandFilterExpression, buildFlashPattern, buildLabelLayer, buildLayersForClass, buildOfflineStyle, buildSectorArcGeoJSON, buildSectorArcsFC, buildSectorsFromFeatures, buildSources, candidateRank, chrtAtonTintExpression, chrtLightTintExpression, collectCandidates, collectClickCandidates, combineWithBandFilter, daymarkColor, decimateFeatures, decodeAreaFeatureProps, decodeBridgeProps, decodeCandidate, decodeNavAidProps, depareColor, depareFillExpression, deriveMarinerName, extractNavAidDesignation, featureIdentity, generateCustomStyle, generateSpriteManifest, generateSpriteSheet, generateStyle, generateStyleJSON, getAvailableLineSymbols, getAvailablePatterns, getAvailablePointSymbols, getCollisionSettings, getDrawPriority, getGridSizeForZoom, getIconExpression, getLabelBehavior, getLabelConfig, getLabelPriority, getLookupEntry, getMaxCellsForZoom, getOrderedClasses, getRasterSvg, getS52SvgString, getS52SymbolStats, getStyleStats, getSymbolSvgString, getThemedS101Svg, getThemedS52Svg, getTopmarkMeaning, hazardColor, hazardFillExpression, iconExpressionForFamily, isLabelLayerVisible, isNavAidLayer, isNavAidLayerVisible, isSoundingLayerVisible, isVisibleInMode, isWaterBodyLayerVisible, labelSortKey, lateralColor, lateralFillExpression, lightColor, lightFillExpression, lightsIconExpression, normalizeStyleMode, normalizeTheme, paginate, parseListCodes, parseSymbolFamily, parseWebhook, patternSpriteId, preprocessLights, preprocessNavAids, preprocessSoundings, preprocessWaterBodies, rasterAtonIconExpression, resolveCustomTheme, resolveRasterImage, resolveS101Color, resolveStyle, resolveTargetClass, s101ArtworkProvenance, sanitizeCustomStyleConfig, scaleSizeValue, scaminToMinZoom, styleModeBand, withinBboxFilter, worldMinusBboxPolygon };
|
|
4308
|
+
export { ALL_NAV_AID_LAYERS, ALL_WATER_BODY_LAYERS, AREA_QUERY_LAYERS, ATON_EXPRESSION_CLASSES, type AheadCoverageCell, type AheadFeatureProperties, type AheadOptions, type AheadResponse, type AlongRouteFeatureProperties, type AlongRouteOptions, type AlongRouteResponse, type AreaInspectResult, type AtlasStyle, type AttachOptions, BAND_DRAW_ORDER, BAND_PRIORITY_RANGES, type BBox, BRIDGE_QUERY_LAYERS, BUILD_MAXZOOM, BUILD_MINZOOM, type BandCode, type BandPriorityRange, type BridgeInspectResult, type BuildOfflineStyleOptions, type BuildSourcesOptions, CHART_BAND_CODES, CHART_CASCADE_CODES, CHART_SECTIONS, CHRTRASTER_REF_CROPS, CHRTRASTER_SVGS, CHRT_ATON_COLORS, CHRT_GLYPH_NAMES, CHRT_GLYPH_SVGS, CHRT_ICON_EXPRESSIONS, CHRT_ICON_PREFIX, CHRT_SDF_GLYPHS, CHRT_STYLE_MODES, type CandidateQueryOptions, type CandidatesEventContext, type CellDeletedEvent, type CellDetail, type CellEventData, type CellNewEvent, type CellUpdatedData, type CellUpdatedEvent, type CellsOptions, type CellsResponse, type ChartSection, Chrt, type ChrtConfig, ChrtError, type ChrtStyleMode, type ChrtStyleOptions, type ChrtStyleTheme, type ChrtSymbolSet, type ClickAnchor, ColorTableName, type CoverageOptions, type CoverageResponse, type CoverageRouteCell, type CoverageRouteOptions, type CoverageRouteResponse, type CoverageSource, type CustomStyleConfig, DEFAULT_CLICK_TOLERANCE, DEFAULT_CUSTOM_STYLE_CONFIG, DEFAULT_INSPECT_CLASS_RANK, DEFAULT_LABEL_SETTINGS, DEFAULT_NAV_AID_SETTINGS, DEFAULT_REGION, DEFAULT_SAFETY_CONTOUR_M, DEFAULT_SOUNDING_SETTINGS, DEFAULT_TILE_BASE_URL, DEFAULT_TILE_REGION, DEFAULT_WATER_BODY_SETTINGS, type DecodedAreaFeature, type DecodedBridge, type DecodedNavAid, type DecodedProperty, type DisplayCategory, type DisplayMode, type FeatureCollection, type FeaturesOptions, type FetchStyleOptions, FileSystemAdapter, type FlashPattern, type FlashPhase, type GenerateCustomStyleOptions, type GeneratedCustomStyle, type GeoJsonFeature, type GeoJsonGeometry, type GeomType, INSPECT_CLASS_RANK, INSPECT_RANK_DEVIATIONS, type InspectCandidate, type InspectCandidateSet, type InspectEnrichment, type InspectEventContext, type InspectNotice, type InspectOptions, type InspectResult, type InspectTargetClass, type InspectableFeature, InteractClient, type InteractEntitlement, InteractError, type InteractErrorCode, type InteractHandle, type InteractMapLike, type InteractMapMouseEvent, LABELED_LAYERS, LABEL_BEHAVIOR, LABEL_LAYER_GROUPS, LABEL_PRIORITY, LAND_REGION, type LabelBehavior, type LabelConfigOptions, type LabelLayerConfig, type LabelSettings, type LookupEntry, type MapLibreStyle, type MapboxStyle, type MapboxVectorSource, type MarineAlert, type MarineAlertsOptions, type MarineAlertsResponse, type MarineConditionsOptions, type MarineConditionsResponse, type MarineForecastOptions, type MarineForecastPeriod, type MarineForecastResponse, type MarineSeas, type MarineStation, type MarineSwellTrain, type MarineWind, type MarineZoneRef, NAUTICAL_SYMBOLS, NAV_AID_LAYER_GROUPS, NAV_AID_QUERY_LAYERS, NON_SOLAS_DISCLAIMER, NON_SOLAS_DISCLAIMER_SHORT, type NauticalCategory, type NauticalSymbol, type NavAidInspectResult, type NavAidSettings, type NearbyMarineStation, type OfflineBundleResponse, type OfflineDownloadOptions, type OfflineDownloadProgress, type OfflineDownloadResult, OfflineError, type OfflineErrorCode, type OfflineFetchStyleOptions, type OfflineHeartbeatOptions, type OfflineRegionSummary, type OfflineRemoveOptions, OfflineStyleError, type OfflineStylePlatform, type OfflineStyleResponse, type PmtilesVectorSource, type QueryFeatureProperties, type QueryOptions, type QueryResponse, RASTER_ATON_CLASSES, RASTER_GLYPH_NAMES, RASTER_ICON_PREFIX, RELIEF_REGION, type ResolvedStyle, type ResolvedTheme, type S101ArtworkProvenance, type S101Feature, S101_AREA_FILL_NAMES, S101_CHART_SECTIONS, S101_FEATURES, S101_ICON_PREFIX, S101_LINE_STYLE_NAMES, S101_NEW_SYMBOLS, S101_NO_OFFICIAL_COUNTERPART, S101_SOURCE_COMMIT, S101_SYMBOL_GROUPS, S101_SYMBOL_NAMES, S52_ATON_LOOKUPS, S52_ATON_LOOKUPS_PAPER, S52_DRAW_ORDER, S52_LOOKUP, S52_PATTERN_SPRITE_PREFIX, SOUNDING_LAYERS, SYMBOL_FAMILIES, SYMBOL_FAMILY_META, SYMBOL_GROUPS, SYMBOL_MAP, type ScaleBand, type SearchCoverageNotice, type SearchHit, type SearchOptions, type SearchResponse, type SectorArcFeature, type SectorArcFeatureCollection, type SectorInfo, type SoundingSettings, type SourceMode, type StyleGeneratorOptions, type StyleLayer, type StyleUrlOptions, type SymbolFamily, type SymbolFamilyMeta, type SymbolGroup, TileAuth, type TileGroup, type TileGroupsResponse, TileTokenError, type TileTokenErrorCode, type TileTokenResponse, type TransformRequest, type TransformedRequest, type VectorSourceSpec, type VesselProfile, WATER_BODY_LAYER_GROUPS, type WaterBodySettings, WeatherEndpoint, type WeatherReading, type WebhookEvent, type WebhookEventType, type WebhookPayload, applyChrtSymbolSet, applyColorTheme, applyCustomStyleSettings, applyRasterSymbolSet, applyS101SymbolSet, atonIconExpression, bandFilterExpression, buildFlashPattern, buildLabelLayer, buildLayersForClass, buildOfflineStyle, buildSectorArcGeoJSON, buildSectorArcsFC, buildSectorsFromFeatures, buildSources, candidateRank, chrtAtonTintExpression, chrtLightTintExpression, collectCandidates, collectClickCandidates, combineWithBandFilter, daymarkColor, decimateFeatures, decodeAreaFeatureProps, decodeBridgeProps, decodeCandidate, decodeNavAidProps, depareColor, depareFillExpression, deriveMarinerName, extractNavAidDesignation, featureIdentity, generateCustomStyle, generateSpriteManifest, generateSpriteSheet, generateStyle, generateStyleJSON, getAvailableLineSymbols, getAvailablePatterns, getAvailablePointSymbols, getCollisionSettings, getDrawPriority, getGridSizeForZoom, getIconExpression, getLabelBehavior, getLabelConfig, getLabelPriority, getLookupEntry, getMaxCellsForZoom, getOrderedClasses, getRasterSvg, getS52SvgString, getS52SymbolStats, getStyleStats, getSymbolSvgString, getThemedS101Svg, getThemedS52Svg, getTopmarkMeaning, hazardColor, hazardFillExpression, iconExpressionForFamily, isLabelLayerVisible, isNavAidLayer, isNavAidLayerVisible, isSoundingLayerVisible, isVisibleInMode, isWaterBodyLayerVisible, labelSortKey, lateralColor, lateralFillExpression, lightColor, lightFillExpression, lightsIconExpression, normalizeStyleMode, normalizeTheme, paginate, parseListCodes, parseSymbolFamily, parseWebhook, patternSpriteId, preprocessLights, preprocessNavAids, preprocessSoundings, preprocessWaterBodies, rasterAtonIconExpression, resolveCustomTheme, resolveRasterImage, resolveS101Color, resolveStyle, resolveTargetClass, s101ArtworkProvenance, sanitizeCustomStyleConfig, scaleSizeValue, scaminToMinZoom, styleModeBand, withinBboxFilter, worldMinusBboxPolygon };
|
package/dist/index.d.ts
CHANGED
|
@@ -1380,6 +1380,25 @@ interface StyleUrlOptions {
|
|
|
1380
1380
|
* `CHRT_STYLE_MODES`). The served document echoes the resolved mode in
|
|
1381
1381
|
* `metadata["chrt:render-mode"]` and the `X-Style-Mode` header. */
|
|
1382
1382
|
mode?: ChrtStyleMode;
|
|
1383
|
+
/** Draw the CHRTland land base under the chart (default off). Adds the
|
|
1384
|
+
* `CHRT_LAND` source and a dozen `chrtland-*` layers, all beneath every
|
|
1385
|
+
* S-57 class so land can never occlude a portrayal.
|
|
1386
|
+
*
|
|
1387
|
+
* **CHRTland is not chart data and does not come from a hydrographic
|
|
1388
|
+
* office** — never present its shoreline to a mariner as charted.
|
|
1389
|
+
*
|
|
1390
|
+
* Needs `CHRT_LAND` on the tile token, which follows the chart sources
|
|
1391
|
+
* your key holds; without it the style request is a 403
|
|
1392
|
+
* `region_not_licensed` rather than a document with dead sources. */
|
|
1393
|
+
land?: boolean;
|
|
1394
|
+
/** Add CHRTland's terrarium hillshade (default off). Separately opt-in
|
|
1395
|
+
* from {@link land} and requires it — `relief` alone is a 400
|
|
1396
|
+
* `relief_requires_land`.
|
|
1397
|
+
*
|
|
1398
|
+
* It also needs a `CHRT_RELIEF` grant that no chart source issues yet,
|
|
1399
|
+
* so this currently returns 403 for every key. It will start working
|
|
1400
|
+
* with no SDK change once that grant ships. */
|
|
1401
|
+
relief?: boolean;
|
|
1383
1402
|
}
|
|
1384
1403
|
interface FetchStyleOptions extends StyleUrlOptions {
|
|
1385
1404
|
signal?: AbortSignal;
|
|
@@ -2989,7 +3008,26 @@ interface PmtilesVectorSource {
|
|
|
2989
3008
|
minzoom: number;
|
|
2990
3009
|
maxzoom: number;
|
|
2991
3010
|
}
|
|
3011
|
+
/**
|
|
3012
|
+
* Terrarium elevation, served as PNG from `CHRT_RELIEF`. Separate from the
|
|
3013
|
+
* vector shapes because MapLibre needs `type: "raster-dem"` and an explicit
|
|
3014
|
+
* `encoding` — a raster-dem source read as a plain raster renders the encoded
|
|
3015
|
+
* RGB as a garish false-colour image rather than as elevation.
|
|
3016
|
+
*/
|
|
3017
|
+
interface RasterDemSource {
|
|
3018
|
+
type: "raster-dem";
|
|
3019
|
+
tiles: string[];
|
|
3020
|
+
encoding: "terrarium";
|
|
3021
|
+
tileSize: number;
|
|
3022
|
+
minzoom: number;
|
|
3023
|
+
maxzoom: number;
|
|
3024
|
+
}
|
|
2992
3025
|
type VectorSourceSpec = MapboxVectorSource | PmtilesVectorSource;
|
|
3026
|
+
type AnySourceSpec = VectorSourceSpec | RasterDemSource;
|
|
3027
|
+
/** CHRTland's vector land base. ADR 0023: its own archive, never chart data. */
|
|
3028
|
+
declare const LAND_REGION = "CHRT_LAND";
|
|
3029
|
+
/** CHRTland's terrarium relief. */
|
|
3030
|
+
declare const RELIEF_REGION = "CHRT_RELIEF";
|
|
2993
3031
|
type SourceMode = "mapbox" | "pmtiles";
|
|
2994
3032
|
/** Canonical source id used in `generateStyle()` — matches the region name
|
|
2995
3033
|
* of the one consolidated PMTiles served by the tile-worker for this region. */
|
|
@@ -3006,6 +3044,17 @@ interface BuildSourcesOptions {
|
|
|
3006
3044
|
buildTag?: string;
|
|
3007
3045
|
/** Override tile-worker origin (e.g. staging). Default: DEFAULT_TILE_BASE_URL. */
|
|
3008
3046
|
tileBaseUrl?: string;
|
|
3047
|
+
/**
|
|
3048
|
+
* Emit the CHRTland vector land base as a second source (ADR 0023). Off by
|
|
3049
|
+
* default: it costs a source, and the region must be granted on the token.
|
|
3050
|
+
*/
|
|
3051
|
+
land?: boolean;
|
|
3052
|
+
/**
|
|
3053
|
+
* Emit CHRTland's terrarium relief as a raster-dem source. Separate from
|
|
3054
|
+
* `land` because relief needs a raster-capable worker AND a grant that
|
|
3055
|
+
* `land-regions.ts` still withholds.
|
|
3056
|
+
*/
|
|
3057
|
+
relief?: boolean;
|
|
3009
3058
|
}
|
|
3010
3059
|
/**
|
|
3011
3060
|
* Build the "sources" block for a CHRT style.
|
|
@@ -3015,7 +3064,7 @@ interface BuildSourcesOptions {
|
|
|
3015
3064
|
* routed by the Worker to the one consolidated PMTiles:
|
|
3016
3065
|
* `${tileBaseUrl}/v1/tiles/{region}/{z}/{x}/{y}.mvt`
|
|
3017
3066
|
*/
|
|
3018
|
-
declare function buildSources(opts?: BuildSourcesOptions): Record<string,
|
|
3067
|
+
declare function buildSources(opts?: BuildSourcesOptions): Record<string, AnySourceSpec>;
|
|
3019
3068
|
|
|
3020
3069
|
/**
|
|
3021
3070
|
* Builds Mapbox GL Style layer specs from S-52 lookup entries.
|
|
@@ -4256,4 +4305,4 @@ declare class Chrt {
|
|
|
4256
4305
|
warmTiles(region?: string): Promise<void>;
|
|
4257
4306
|
}
|
|
4258
4307
|
|
|
4259
|
-
export { ALL_NAV_AID_LAYERS, ALL_WATER_BODY_LAYERS, AREA_QUERY_LAYERS, ATON_EXPRESSION_CLASSES, type AheadCoverageCell, type AheadFeatureProperties, type AheadOptions, type AheadResponse, type AlongRouteFeatureProperties, type AlongRouteOptions, type AlongRouteResponse, type AreaInspectResult, type AtlasStyle, type AttachOptions, BAND_DRAW_ORDER, BAND_PRIORITY_RANGES, type BBox, BRIDGE_QUERY_LAYERS, BUILD_MAXZOOM, BUILD_MINZOOM, type BandCode, type BandPriorityRange, type BridgeInspectResult, type BuildOfflineStyleOptions, type BuildSourcesOptions, CHART_BAND_CODES, CHART_CASCADE_CODES, CHART_SECTIONS, CHRTRASTER_REF_CROPS, CHRTRASTER_SVGS, CHRT_ATON_COLORS, CHRT_GLYPH_NAMES, CHRT_GLYPH_SVGS, CHRT_ICON_EXPRESSIONS, CHRT_ICON_PREFIX, CHRT_SDF_GLYPHS, CHRT_STYLE_MODES, type CandidateQueryOptions, type CandidatesEventContext, type CellDeletedEvent, type CellDetail, type CellEventData, type CellNewEvent, type CellUpdatedData, type CellUpdatedEvent, type CellsOptions, type CellsResponse, type ChartSection, Chrt, type ChrtConfig, ChrtError, type ChrtStyleMode, type ChrtStyleOptions, type ChrtStyleTheme, type ChrtSymbolSet, type ClickAnchor, ColorTableName, type CoverageOptions, type CoverageResponse, type CoverageRouteCell, type CoverageRouteOptions, type CoverageRouteResponse, type CoverageSource, type CustomStyleConfig, DEFAULT_CLICK_TOLERANCE, DEFAULT_CUSTOM_STYLE_CONFIG, DEFAULT_INSPECT_CLASS_RANK, DEFAULT_LABEL_SETTINGS, DEFAULT_NAV_AID_SETTINGS, DEFAULT_REGION, DEFAULT_SAFETY_CONTOUR_M, DEFAULT_SOUNDING_SETTINGS, DEFAULT_TILE_BASE_URL, DEFAULT_TILE_REGION, DEFAULT_WATER_BODY_SETTINGS, type DecodedAreaFeature, type DecodedBridge, type DecodedNavAid, type DecodedProperty, type DisplayCategory, type DisplayMode, type FeatureCollection, type FeaturesOptions, type FetchStyleOptions, FileSystemAdapter, type FlashPattern, type FlashPhase, type GenerateCustomStyleOptions, type GeneratedCustomStyle, type GeoJsonFeature, type GeoJsonGeometry, type GeomType, INSPECT_CLASS_RANK, INSPECT_RANK_DEVIATIONS, type InspectCandidate, type InspectCandidateSet, type InspectEnrichment, type InspectEventContext, type InspectNotice, type InspectOptions, type InspectResult, type InspectTargetClass, type InspectableFeature, InteractClient, type InteractEntitlement, InteractError, type InteractErrorCode, type InteractHandle, type InteractMapLike, type InteractMapMouseEvent, LABELED_LAYERS, LABEL_BEHAVIOR, LABEL_LAYER_GROUPS, LABEL_PRIORITY, type LabelBehavior, type LabelConfigOptions, type LabelLayerConfig, type LabelSettings, type LookupEntry, type MapLibreStyle, type MapboxStyle, type MapboxVectorSource, type MarineAlert, type MarineAlertsOptions, type MarineAlertsResponse, type MarineConditionsOptions, type MarineConditionsResponse, type MarineForecastOptions, type MarineForecastPeriod, type MarineForecastResponse, type MarineSeas, type MarineStation, type MarineSwellTrain, type MarineWind, type MarineZoneRef, NAUTICAL_SYMBOLS, NAV_AID_LAYER_GROUPS, NAV_AID_QUERY_LAYERS, NON_SOLAS_DISCLAIMER, NON_SOLAS_DISCLAIMER_SHORT, type NauticalCategory, type NauticalSymbol, type NavAidInspectResult, type NavAidSettings, type NearbyMarineStation, type OfflineBundleResponse, type OfflineDownloadOptions, type OfflineDownloadProgress, type OfflineDownloadResult, OfflineError, type OfflineErrorCode, type OfflineFetchStyleOptions, type OfflineHeartbeatOptions, type OfflineRegionSummary, type OfflineRemoveOptions, OfflineStyleError, type OfflineStylePlatform, type OfflineStyleResponse, type PmtilesVectorSource, type QueryFeatureProperties, type QueryOptions, type QueryResponse, RASTER_ATON_CLASSES, RASTER_GLYPH_NAMES, RASTER_ICON_PREFIX, type ResolvedStyle, type ResolvedTheme, type S101ArtworkProvenance, type S101Feature, S101_AREA_FILL_NAMES, S101_CHART_SECTIONS, S101_FEATURES, S101_ICON_PREFIX, S101_LINE_STYLE_NAMES, S101_NEW_SYMBOLS, S101_NO_OFFICIAL_COUNTERPART, S101_SOURCE_COMMIT, S101_SYMBOL_GROUPS, S101_SYMBOL_NAMES, S52_ATON_LOOKUPS, S52_ATON_LOOKUPS_PAPER, S52_DRAW_ORDER, S52_LOOKUP, S52_PATTERN_SPRITE_PREFIX, SOUNDING_LAYERS, SYMBOL_FAMILIES, SYMBOL_FAMILY_META, SYMBOL_GROUPS, SYMBOL_MAP, type ScaleBand, type SearchCoverageNotice, type SearchHit, type SearchOptions, type SearchResponse, type SectorArcFeature, type SectorArcFeatureCollection, type SectorInfo, type SoundingSettings, type SourceMode, type StyleGeneratorOptions, type StyleLayer, type StyleUrlOptions, type SymbolFamily, type SymbolFamilyMeta, type SymbolGroup, TileAuth, type TileGroup, type TileGroupsResponse, TileTokenError, type TileTokenErrorCode, type TileTokenResponse, type TransformRequest, type TransformedRequest, type VectorSourceSpec, type VesselProfile, WATER_BODY_LAYER_GROUPS, type WaterBodySettings, WeatherEndpoint, type WeatherReading, type WebhookEvent, type WebhookEventType, type WebhookPayload, applyChrtSymbolSet, applyColorTheme, applyCustomStyleSettings, applyRasterSymbolSet, applyS101SymbolSet, atonIconExpression, bandFilterExpression, buildFlashPattern, buildLabelLayer, buildLayersForClass, buildOfflineStyle, buildSectorArcGeoJSON, buildSectorArcsFC, buildSectorsFromFeatures, buildSources, candidateRank, chrtAtonTintExpression, chrtLightTintExpression, collectCandidates, collectClickCandidates, combineWithBandFilter, daymarkColor, decimateFeatures, decodeAreaFeatureProps, decodeBridgeProps, decodeCandidate, decodeNavAidProps, depareColor, depareFillExpression, deriveMarinerName, extractNavAidDesignation, featureIdentity, generateCustomStyle, generateSpriteManifest, generateSpriteSheet, generateStyle, generateStyleJSON, getAvailableLineSymbols, getAvailablePatterns, getAvailablePointSymbols, getCollisionSettings, getDrawPriority, getGridSizeForZoom, getIconExpression, getLabelBehavior, getLabelConfig, getLabelPriority, getLookupEntry, getMaxCellsForZoom, getOrderedClasses, getRasterSvg, getS52SvgString, getS52SymbolStats, getStyleStats, getSymbolSvgString, getThemedS101Svg, getThemedS52Svg, getTopmarkMeaning, hazardColor, hazardFillExpression, iconExpressionForFamily, isLabelLayerVisible, isNavAidLayer, isNavAidLayerVisible, isSoundingLayerVisible, isVisibleInMode, isWaterBodyLayerVisible, labelSortKey, lateralColor, lateralFillExpression, lightColor, lightFillExpression, lightsIconExpression, normalizeStyleMode, normalizeTheme, paginate, parseListCodes, parseSymbolFamily, parseWebhook, patternSpriteId, preprocessLights, preprocessNavAids, preprocessSoundings, preprocessWaterBodies, rasterAtonIconExpression, resolveCustomTheme, resolveRasterImage, resolveS101Color, resolveStyle, resolveTargetClass, s101ArtworkProvenance, sanitizeCustomStyleConfig, scaleSizeValue, scaminToMinZoom, styleModeBand, withinBboxFilter, worldMinusBboxPolygon };
|
|
4308
|
+
export { ALL_NAV_AID_LAYERS, ALL_WATER_BODY_LAYERS, AREA_QUERY_LAYERS, ATON_EXPRESSION_CLASSES, type AheadCoverageCell, type AheadFeatureProperties, type AheadOptions, type AheadResponse, type AlongRouteFeatureProperties, type AlongRouteOptions, type AlongRouteResponse, type AreaInspectResult, type AtlasStyle, type AttachOptions, BAND_DRAW_ORDER, BAND_PRIORITY_RANGES, type BBox, BRIDGE_QUERY_LAYERS, BUILD_MAXZOOM, BUILD_MINZOOM, type BandCode, type BandPriorityRange, type BridgeInspectResult, type BuildOfflineStyleOptions, type BuildSourcesOptions, CHART_BAND_CODES, CHART_CASCADE_CODES, CHART_SECTIONS, CHRTRASTER_REF_CROPS, CHRTRASTER_SVGS, CHRT_ATON_COLORS, CHRT_GLYPH_NAMES, CHRT_GLYPH_SVGS, CHRT_ICON_EXPRESSIONS, CHRT_ICON_PREFIX, CHRT_SDF_GLYPHS, CHRT_STYLE_MODES, type CandidateQueryOptions, type CandidatesEventContext, type CellDeletedEvent, type CellDetail, type CellEventData, type CellNewEvent, type CellUpdatedData, type CellUpdatedEvent, type CellsOptions, type CellsResponse, type ChartSection, Chrt, type ChrtConfig, ChrtError, type ChrtStyleMode, type ChrtStyleOptions, type ChrtStyleTheme, type ChrtSymbolSet, type ClickAnchor, ColorTableName, type CoverageOptions, type CoverageResponse, type CoverageRouteCell, type CoverageRouteOptions, type CoverageRouteResponse, type CoverageSource, type CustomStyleConfig, DEFAULT_CLICK_TOLERANCE, DEFAULT_CUSTOM_STYLE_CONFIG, DEFAULT_INSPECT_CLASS_RANK, DEFAULT_LABEL_SETTINGS, DEFAULT_NAV_AID_SETTINGS, DEFAULT_REGION, DEFAULT_SAFETY_CONTOUR_M, DEFAULT_SOUNDING_SETTINGS, DEFAULT_TILE_BASE_URL, DEFAULT_TILE_REGION, DEFAULT_WATER_BODY_SETTINGS, type DecodedAreaFeature, type DecodedBridge, type DecodedNavAid, type DecodedProperty, type DisplayCategory, type DisplayMode, type FeatureCollection, type FeaturesOptions, type FetchStyleOptions, FileSystemAdapter, type FlashPattern, type FlashPhase, type GenerateCustomStyleOptions, type GeneratedCustomStyle, type GeoJsonFeature, type GeoJsonGeometry, type GeomType, INSPECT_CLASS_RANK, INSPECT_RANK_DEVIATIONS, type InspectCandidate, type InspectCandidateSet, type InspectEnrichment, type InspectEventContext, type InspectNotice, type InspectOptions, type InspectResult, type InspectTargetClass, type InspectableFeature, InteractClient, type InteractEntitlement, InteractError, type InteractErrorCode, type InteractHandle, type InteractMapLike, type InteractMapMouseEvent, LABELED_LAYERS, LABEL_BEHAVIOR, LABEL_LAYER_GROUPS, LABEL_PRIORITY, LAND_REGION, type LabelBehavior, type LabelConfigOptions, type LabelLayerConfig, type LabelSettings, type LookupEntry, type MapLibreStyle, type MapboxStyle, type MapboxVectorSource, type MarineAlert, type MarineAlertsOptions, type MarineAlertsResponse, type MarineConditionsOptions, type MarineConditionsResponse, type MarineForecastOptions, type MarineForecastPeriod, type MarineForecastResponse, type MarineSeas, type MarineStation, type MarineSwellTrain, type MarineWind, type MarineZoneRef, NAUTICAL_SYMBOLS, NAV_AID_LAYER_GROUPS, NAV_AID_QUERY_LAYERS, NON_SOLAS_DISCLAIMER, NON_SOLAS_DISCLAIMER_SHORT, type NauticalCategory, type NauticalSymbol, type NavAidInspectResult, type NavAidSettings, type NearbyMarineStation, type OfflineBundleResponse, type OfflineDownloadOptions, type OfflineDownloadProgress, type OfflineDownloadResult, OfflineError, type OfflineErrorCode, type OfflineFetchStyleOptions, type OfflineHeartbeatOptions, type OfflineRegionSummary, type OfflineRemoveOptions, OfflineStyleError, type OfflineStylePlatform, type OfflineStyleResponse, type PmtilesVectorSource, type QueryFeatureProperties, type QueryOptions, type QueryResponse, RASTER_ATON_CLASSES, RASTER_GLYPH_NAMES, RASTER_ICON_PREFIX, RELIEF_REGION, type ResolvedStyle, type ResolvedTheme, type S101ArtworkProvenance, type S101Feature, S101_AREA_FILL_NAMES, S101_CHART_SECTIONS, S101_FEATURES, S101_ICON_PREFIX, S101_LINE_STYLE_NAMES, S101_NEW_SYMBOLS, S101_NO_OFFICIAL_COUNTERPART, S101_SOURCE_COMMIT, S101_SYMBOL_GROUPS, S101_SYMBOL_NAMES, S52_ATON_LOOKUPS, S52_ATON_LOOKUPS_PAPER, S52_DRAW_ORDER, S52_LOOKUP, S52_PATTERN_SPRITE_PREFIX, SOUNDING_LAYERS, SYMBOL_FAMILIES, SYMBOL_FAMILY_META, SYMBOL_GROUPS, SYMBOL_MAP, type ScaleBand, type SearchCoverageNotice, type SearchHit, type SearchOptions, type SearchResponse, type SectorArcFeature, type SectorArcFeatureCollection, type SectorInfo, type SoundingSettings, type SourceMode, type StyleGeneratorOptions, type StyleLayer, type StyleUrlOptions, type SymbolFamily, type SymbolFamilyMeta, type SymbolGroup, TileAuth, type TileGroup, type TileGroupsResponse, TileTokenError, type TileTokenErrorCode, type TileTokenResponse, type TransformRequest, type TransformedRequest, type VectorSourceSpec, type VesselProfile, WATER_BODY_LAYER_GROUPS, type WaterBodySettings, WeatherEndpoint, type WeatherReading, type WebhookEvent, type WebhookEventType, type WebhookPayload, applyChrtSymbolSet, applyColorTheme, applyCustomStyleSettings, applyRasterSymbolSet, applyS101SymbolSet, atonIconExpression, bandFilterExpression, buildFlashPattern, buildLabelLayer, buildLayersForClass, buildOfflineStyle, buildSectorArcGeoJSON, buildSectorArcsFC, buildSectorsFromFeatures, buildSources, candidateRank, chrtAtonTintExpression, chrtLightTintExpression, collectCandidates, collectClickCandidates, combineWithBandFilter, daymarkColor, decimateFeatures, decodeAreaFeatureProps, decodeBridgeProps, decodeCandidate, decodeNavAidProps, depareColor, depareFillExpression, deriveMarinerName, extractNavAidDesignation, featureIdentity, generateCustomStyle, generateSpriteManifest, generateSpriteSheet, generateStyle, generateStyleJSON, getAvailableLineSymbols, getAvailablePatterns, getAvailablePointSymbols, getCollisionSettings, getDrawPriority, getGridSizeForZoom, getIconExpression, getLabelBehavior, getLabelConfig, getLabelPriority, getLookupEntry, getMaxCellsForZoom, getOrderedClasses, getRasterSvg, getS52SvgString, getS52SymbolStats, getStyleStats, getSymbolSvgString, getThemedS101Svg, getThemedS52Svg, getTopmarkMeaning, hazardColor, hazardFillExpression, iconExpressionForFamily, isLabelLayerVisible, isNavAidLayer, isNavAidLayerVisible, isSoundingLayerVisible, isVisibleInMode, isWaterBodyLayerVisible, labelSortKey, lateralColor, lateralFillExpression, lightColor, lightFillExpression, lightsIconExpression, normalizeStyleMode, normalizeTheme, paginate, parseListCodes, parseSymbolFamily, parseWebhook, patternSpriteId, preprocessLights, preprocessNavAids, preprocessSoundings, preprocessWaterBodies, rasterAtonIconExpression, resolveCustomTheme, resolveRasterImage, resolveS101Color, resolveStyle, resolveTargetClass, s101ArtworkProvenance, sanitizeCustomStyleConfig, scaleSizeValue, scaminToMinZoom, styleModeBand, withinBboxFilter, worldMinusBboxPolygon };
|