@chrtco/sdk 0.10.40 → 0.10.42

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 CHANGED
@@ -13,6 +13,28 @@ All notable changes to `@chrtco/sdk` will be documented in this file.
13
13
  emits for the relief source. Exported for consumers that describe that
14
14
  source themselves, such as the tile-worker's TileJSON.
15
15
 
16
+ ### Fixed
17
+ - **`offline.download()` left a second copy of every pack in a browser's HTTP
18
+ cache.** In a browser, an Electron renderer or Electron `net.fetch`, the
19
+ bundle GET was stored in the profile's disk cache as well as written through
20
+ the `fs` adapter, so each pack cost about twice its size on disk and pushed
21
+ tiles out of the cache. The signed URL is never fetched twice, so that copy
22
+ was never read. The bundle GET, including a ranged resume, now passes
23
+ `cache: "no-store"`. Node, Bun and Deno have no HTTP cache and behave as
24
+ before. On a runtime that rejects the field, such as Cloudflare Workers
25
+ before compatibility date 2024-11-11, it is left off. The API calls around
26
+ the download are unchanged.
27
+ - **The `CHRT_LAND` and `CHRT_RELIEF` sources carried no attribution.**
28
+ `generateStyle({ land: true })` emitted a `CHRT_LAND` source with no
29
+ `attribution`, so a map using MapLibre's attribution control showed no
30
+ credit for CHRTland — which is built from OpenStreetMap, whose ODbL requires
31
+ `© OpenStreetMap contributors` wherever the map is shown. The source now
32
+ carries `LAND_ATTRIBUTION`, and `CHRT_RELIEF` names its source, USGS 3DEP
33
+ (`RELIEF_ATTRIBUTION`; public domain, a courtesy). `CHRT_BASE` already
34
+ carried `BASE_ATTRIBUTION` and is unchanged; the chart source's credit is
35
+ still the tile-worker's to stamp. `RasterDemSource` gains the optional
36
+ `attribution` field `PmtilesVectorSource` already had.
37
+
16
38
  ## [0.10.40]
17
39
 
18
40
  The first publish since 0.10.39 (2026-09-11, from `ada7e73e`). The publish
@@ -161,7 +161,12 @@ var S52_DUSK = {
161
161
  CHMGF: "#905090",
162
162
  CHWHT: "#90a0a0",
163
163
  CHCOR: "#a06030",
164
- SNDG1: "#606060",
164
+ // Deeper-than-safety soundings. Was #606060, which measured 2.39:1 on this
165
+ // palette's DEPMD (#7ba6b8). DUSK water is LIGHT, so the only way to 3:1 is
166
+ // darker: #505050 = 3.07:1 on DEPMD, 4.09:1 on DEPDW (spec: #292e2e). The
167
+ // shoaler SNDG2 stays the louder numeral through its UIBCK halo cut-out.
168
+ // Guarded with NIGHT's by `sounding-legibility.test.ts`; see S52_NIGHT.SNDG1.
169
+ SNDG1: "#505050",
165
170
  SNDG2: "#b0b0b0",
166
171
  DEPSC: "#606060",
167
172
  DEPCN: "#2E2E2E",
@@ -232,7 +237,24 @@ var S52_NIGHT = {
232
237
  CHMGF: "#482848",
233
238
  CHWHT: "#484840",
234
239
  CHCOR: "#683818",
235
- SNDG1: "#383028",
240
+ // ⚠ DELIBERATE DEVIATION from the published S-52 NIGHT value (#1f2223),
241
+ // for the reason DEPCN's below gives, on the deeper-than-safety soundings.
242
+ //
243
+ // Reported 2026-09-30 at night on CHRTdesktop (Raspberry Pi 4): "we mute
244
+ // out the ones that are 'deep' but I need to still be able to see them."
245
+ // The previous value, #383028, measured 1.37:1 on DEPDW and 1.08:1 on
246
+ // DEPMD: the muted soundings had disappeared entirely.
247
+ //
248
+ // #897350 is SNDG2 (#c8aa78) scaled to 43% of its linear light, so it keeps
249
+ // SNDG2's hue (the NIGHT table's warm linework family, kind to a
250
+ // dark-adapted eye and to red night). Against this palette's water it
251
+ // measures 3.10:1 on DEPMD and 3.91:1 on DEPDW, which clears the 3:1 floor.
252
+ // It is 0.49x SNDG2's contrast on any of them, so the eye still goes to
253
+ // the shoal soundings first. On the lighter DEPMS/DEPVS water the UIBCK
254
+ // halo carries it: fill against halo is 4.37:1.
255
+ // The window is narrow (luminance 0.175-0.187 meets both conditions), and
256
+ // `sounding-legibility.test.ts` pins both ends for every symbol family.
257
+ SNDG1: "#897350",
236
258
  SNDG2: "#c8aa78",
237
259
  DEPSC: "#383028",
238
260
  // ⚠ DELIBERATE DEVIATION from the published S-52 NIGHT value (#1f2223),