@chrtco/sdk 0.10.38 → 0.10.39

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/index.js CHANGED
@@ -28841,6 +28841,17 @@ function isExemptOpaqueFill(layer) {
28841
28841
  }
28842
28842
  return false;
28843
28843
  }
28844
+ var GROUND_FILL_CLASSES = /* @__PURE__ */ new Set([
28845
+ ...DOMINANCE_EXEMPT_FILL_CLASSES,
28846
+ "RIVERS"
28847
+ ]);
28848
+ function isGroundFill(layer) {
28849
+ if (layer.type !== "fill") return false;
28850
+ for (const cls of GROUND_FILL_CLASSES) {
28851
+ if (layer.id.startsWith(`s52-${cls}-`)) return true;
28852
+ }
28853
+ return false;
28854
+ }
28844
28855
  var FILL_FLOOR_FREE_BANDS = /* @__PURE__ */ new Set([
28845
28856
  "1",
28846
28857
  "2",
@@ -28848,10 +28859,10 @@ var FILL_FLOOR_FREE_BANDS = /* @__PURE__ */ new Set([
28848
28859
  ]);
28849
28860
  function bandVariantMinzoom(layer, B) {
28850
28861
  const classMinzoom = layer.minzoom ?? 0;
28851
- if (isExemptOpaqueFill(layer) && FILL_FLOOR_FREE_BANDS.has(B)) {
28852
- return classMinzoom;
28862
+ if (isGroundFill(layer) && FILL_FLOOR_FREE_BANDS.has(B)) {
28863
+ return 0;
28853
28864
  }
28854
- if (isExemptOpaqueFill(layer)) {
28865
+ if (isGroundFill(layer)) {
28855
28866
  return BAND_PRIORITY_RANGES[B].minzoom;
28856
28867
  }
28857
28868
  return Math.max(classMinzoom, BAND_PRIORITY_RANGES[B].minzoom);