Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/tile-service-nullable-encoded-url.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@feltmaps/js-sdk": patch
---

Make `RasterLayerSource.encodedTileTemplateUrl` nullable (`string | null`). TileService layers (WMS, WMTS, ArcGIS) serve pre-rendered image tiles and have no encoded tile URL.
14 changes: 14 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# @feltmaps/js-sdk

Public JS SDK for embedding and controlling Felt maps. Two entry points: `client` (external consumers) and `handler` (internal, used by the Felt app).

## Commands

- `npm run check` — full validation (bundle, format, API, types, tests, docs)
- `npm run build` — compile + generate docs
- `npm run update-api` — regenerate `etc/js-sdk.api.md` after API changes (stage before `npm run check`)

## Key constraints

- Every change needs a changeset (`npm run changeset`).
- See `DEVELOPING.md` for module structure and `RELEASING.md` for the branching/release model.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions src/modules/layers/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,9 @@ export interface RasterLayerSource {
imageTileTemplateUrl: string;

/**
* A URL template for fetching encoded tiles for the raster.
* A URL template for fetching encoded tiles for the raster, or `null` for
* TileService layers (WMS, WMTS, ArcGIS) that serve pre-rendered image tiles
* without per-pixel encoding.
*
* The encoded raster value can be calculated from the red, green, and blue values of the pixel
* using the following formula:
Expand All @@ -158,7 +160,7 @@ export interface RasterLayerSource {
* base + (RED * 256 * 256 + GREEN * 256 + BLUE) * interval
* ```
*/
encodedTileTemplateUrl: string;
encodedTileTemplateUrl: string | null;

/**
* List of encoded raster bands
Expand Down
Loading