@chrtco/sdk 0.10.24 → 0.10.25
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/dist/atlas/browser.cjs +20 -3
- package/dist/atlas/browser.cjs.map +1 -1
- package/dist/atlas/browser.js +20 -3
- package/dist/atlas/browser.js.map +1 -1
- package/dist/index.cjs +45 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +45 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4764,7 +4764,7 @@ var S52_DAY = {
|
|
|
4764
4764
|
SNDG1: "#7d898c",
|
|
4765
4765
|
SNDG2: "#070707",
|
|
4766
4766
|
DEPSC: "#525a5c",
|
|
4767
|
-
DEPCN: "#
|
|
4767
|
+
DEPCN: "#555555",
|
|
4768
4768
|
// Utility / infrastructure
|
|
4769
4769
|
UINFD: "#070707",
|
|
4770
4770
|
UINFF: "#7d898c",
|
|
@@ -4838,7 +4838,7 @@ var S52_DUSK = {
|
|
|
4838
4838
|
SNDG1: "#606060",
|
|
4839
4839
|
SNDG2: "#b0b0b0",
|
|
4840
4840
|
DEPSC: "#606060",
|
|
4841
|
-
DEPCN: "#
|
|
4841
|
+
DEPCN: "#2E2E2E",
|
|
4842
4842
|
UINFD: "#b0b0b0",
|
|
4843
4843
|
UINFF: "#606060",
|
|
4844
4844
|
UINFR: "#b05060",
|
|
@@ -4909,7 +4909,24 @@ var S52_NIGHT = {
|
|
|
4909
4909
|
SNDG1: "#383028",
|
|
4910
4910
|
SNDG2: "#c8aa78",
|
|
4911
4911
|
DEPSC: "#383028",
|
|
4912
|
-
|
|
4912
|
+
// ⚠ DELIBERATE DEVIATION from the published S-52 NIGHT value (#1f2223),
|
|
4913
|
+
// recorded here because `docs/validation/s52-spec-gap-matrix.json` tracks
|
|
4914
|
+
// this token as `value-differs` and the CHRTstyles programme is bringing
|
|
4915
|
+
// colours TO spec — this one moves further away, on purpose.
|
|
4916
|
+
//
|
|
4917
|
+
// Spec NIGHT DEPCN is near-black, which measures ~1.1:1 against this
|
|
4918
|
+
// palette's own deep water (#051a28). S-52's NIGHT table assumes a
|
|
4919
|
+
// dark-adapted eye in a darkened wheelhouse; on a phone or a laptop at
|
|
4920
|
+
// anchor it is not dim, it is absent — reported as "can't see bottom
|
|
4921
|
+
// contours in night mode only". A contour nobody can see fails the
|
|
4922
|
+
// standard's intent while matching its number.
|
|
4923
|
+
//
|
|
4924
|
+
// The palette already makes this trade elsewhere and in the same
|
|
4925
|
+
// direction: NIGHT's CHBLK/CSTLN/OUTLW are #c8aa78, light warm linework on
|
|
4926
|
+
// dark water. This value is that family, dimmed to stay subordinate to the
|
|
4927
|
+
// coastline. Revisit with the CHRTstyles programme, which owns the
|
|
4928
|
+
// spec-vs-legibility call across all 63 tokens.
|
|
4929
|
+
DEPCN: "#A68E84",
|
|
4913
4930
|
UINFD: "#c8aa78",
|
|
4914
4931
|
UINFF: "#383028",
|
|
4915
4932
|
UINFR: "#682030",
|
|
@@ -5843,7 +5860,16 @@ var S52_LOOKUP = {
|
|
|
5843
5860
|
category: "Depths",
|
|
5844
5861
|
displayCategory: "STANDARD",
|
|
5845
5862
|
int1Ref: "I30",
|
|
5846
|
-
|
|
5863
|
+
// S-52 names a dedicated depth-contour colour, and this used the shared
|
|
5864
|
+
// chart-grey instead. Reported 2026-09-02: "can't see bottom contours in
|
|
5865
|
+
// night mode only" — measured at 1.06:1 against the deepest NIGHT water,
|
|
5866
|
+
// which is invisible. DAY was 2.00:1 and DUSK 1.63:1 off the same token,
|
|
5867
|
+
// so the bug was worst where the palette is darkest.
|
|
5868
|
+
//
|
|
5869
|
+
// CHGRD is shared by dozens of linestyles (s52-linestyles-generated.ts),
|
|
5870
|
+
// so it could not be retuned for contours without moving all of them.
|
|
5871
|
+
// DEPCN exists in all three palettes and is the token S-52 specifies.
|
|
5872
|
+
style: { type: "line", paint: { "line-color": "DEPCN", "line-width": 0.5 } },
|
|
5847
5873
|
viewingGroup: 13030,
|
|
5848
5874
|
scamin: 45e3
|
|
5849
5875
|
},
|
|
@@ -29633,6 +29659,7 @@ var DOMINANCE_EXEMPT_CLASSES = /* @__PURE__ */ new Set([
|
|
|
29633
29659
|
"RTPBCN",
|
|
29634
29660
|
"RDOSTA"
|
|
29635
29661
|
]);
|
|
29662
|
+
var FINE_LAND_REPAINT_MIN_BAND = 4;
|
|
29636
29663
|
function isDominanceExempt(layer) {
|
|
29637
29664
|
for (const cls of DOMINANCE_EXEMPT_CLASSES) {
|
|
29638
29665
|
if (layer.id.startsWith(`s52-${cls}-`)) return true;
|
|
@@ -30142,6 +30169,20 @@ function generateStyle(palette = "DAY", opts = {}) {
|
|
|
30142
30169
|
repaint.push(domVariant);
|
|
30143
30170
|
}
|
|
30144
30171
|
}
|
|
30172
|
+
if (parseInt(b, 10) >= FINE_LAND_REPAINT_MIN_BAND) {
|
|
30173
|
+
for (const l of relocated.filter(
|
|
30174
|
+
(x) => bandOf(x) === b && isLndareFill(x)
|
|
30175
|
+
)) {
|
|
30176
|
+
const src = l;
|
|
30177
|
+
const landClone = {
|
|
30178
|
+
...l,
|
|
30179
|
+
id: `${src.id}-overpair`,
|
|
30180
|
+
metadata: { ...src.metadata ?? {}, "chrt:role": "charted-land-repaint" }
|
|
30181
|
+
};
|
|
30182
|
+
delete landClone.maxzoom;
|
|
30183
|
+
repaint.push(landClone);
|
|
30184
|
+
}
|
|
30185
|
+
}
|
|
30145
30186
|
}
|
|
30146
30187
|
const isCoalneLine = (l) => /^s52-COALNE-line-band\d(-domBy\d)?$/.test(l.id);
|
|
30147
30188
|
for (const l of layers.filter(isCoalneLine)) {
|