@tileflow/maps 0.1.0-alpha.12 → 0.1.0-alpha.14
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/README.md +40 -40
- package/THIRD_PARTY_NOTICES.md +17 -7
- package/assets/README.md +14 -9
- package/assets/soundings/icons/soundings-boat-hoist.svg +10 -0
- package/assets/soundings/icons/soundings-boatyard.svg +6 -0
- package/assets/soundings/icons/soundings-distance-mark.svg +9 -0
- package/assets/soundings/icons/soundings-facility.svg +6 -0
- package/assets/soundings/icons/soundings-fuel-station.svg +7 -0
- package/assets/soundings/icons/soundings-marina.svg +9 -0
- package/assets/soundings/icons/soundings-notice-information.svg +10 -0
- package/assets/soundings/icons/soundings-notice-prohibition.svg +9 -0
- package/assets/soundings/icons/soundings-notice-recommendation.svg +9 -0
- package/assets/soundings/icons/soundings-notice-regulation.svg +9 -0
- package/assets/soundings/icons/soundings-notice-restriction.svg +10 -0
- package/assets/soundings/icons/soundings-notice.svg +11 -0
- package/assets/soundings/icons/soundings-pump-out.svg +8 -0
- package/assets/soundings/icons/soundings-slipway.svg +6 -0
- package/assets/soundings/icons/soundings-visitor-berth.svg +10 -0
- package/assets/soundings/icons/soundings-water-tap.svg +10 -0
- package/assets/soundings/icons/tileflow.icons.json +64 -0
- package/assets/streets/build-trees.mjs +163 -35
- package/assets/streets/fonts/DINish-Bold.ttf +0 -0
- package/assets/streets/fonts/DINish-Medium.ttf +0 -0
- package/assets/streets/fonts/LICENSE-DINish.txt +93 -0
- package/assets/streets/fonts/LICENSE-NotoSans.txt +94 -0
- package/assets/streets/fonts/LICENSE.txt +193 -0
- package/assets/streets/fonts/NotoSans-Bold.ttf +0 -0
- package/assets/streets/fonts/NotoSans-Italic.ttf +0 -0
- package/assets/streets/fonts/NotoSans-Regular.ttf +0 -0
- package/assets/streets/fonts/README.md +18 -0
- package/assets/streets/icons/streets-tree-conifer-dark.pattern.svg +200 -54
- package/assets/streets/icons/streets-tree-conifer.pattern.svg +200 -54
- package/assets/streets/icons/streets-tree-open-dark.pattern.svg +200 -105
- package/assets/streets/icons/streets-tree-open.pattern.svg +200 -105
- package/assets/streets/icons/streets-tree-round-dark.pattern.svg +158 -105
- package/assets/streets/icons/streets-tree-round.pattern.svg +158 -105
- package/assets/streets/icons/streets-tree-tall-dark.pattern.svg +156 -105
- package/assets/streets/icons/streets-tree-tall.pattern.svg +156 -105
- package/assets/streets/models/streets-tree-conifer.far.glb +0 -0
- package/assets/streets/models/streets-tree-conifer.glb +0 -0
- package/assets/streets/models/streets-tree-open.far.glb +0 -0
- package/assets/streets/models/streets-tree-open.glb +0 -0
- package/assets/streets/models/streets-tree-round.far.glb +0 -0
- package/assets/streets/models/streets-tree-round.glb +0 -0
- package/assets/streets/models/streets-tree-tall.far.glb +0 -0
- package/assets/streets/models/streets-tree-tall.glb +0 -0
- package/dist/index.d.ts +19 -9
- package/dist/index.js +168 -53
- package/docs/design-and-assets.md +8 -5
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -25,6 +25,7 @@ function packageDirectory(path) {
|
|
|
25
25
|
return Object.freeze({ kind: "package-directory", package: "@tileflow/maps", path });
|
|
26
26
|
}
|
|
27
27
|
var streetsIcons = packageDirectory("assets/streets/icons");
|
|
28
|
+
var streetsFonts = packageDirectory("assets/streets/fonts");
|
|
28
29
|
var streetsModels = packageDirectory("assets/streets/models");
|
|
29
30
|
var map1777Fonts = packageDirectory("assets/map-1777/fonts");
|
|
30
31
|
var map1777Icons = packageDirectory("assets/map-1777/icons");
|
|
@@ -752,7 +753,6 @@ var baedeker = bindOfficialMapTheme(
|
|
|
752
753
|
attribution: 'Terrain: <a href="https://mapterhorn.com/attribution">\xA9 Mapterhorn</a>',
|
|
753
754
|
contours: {
|
|
754
755
|
demMaxZoom: 12,
|
|
755
|
-
demUrl: "https://tiles.mapterhorn.com/{z}/{x}/{y}.webp",
|
|
756
756
|
index: {
|
|
757
757
|
color: baedekerPalette.hachure,
|
|
758
758
|
opacity: 0.5,
|
|
@@ -2055,7 +2055,6 @@ var blueprint = bindOfficialMapTheme(
|
|
|
2055
2055
|
attribution: 'Terrain: <a href="https://mapterhorn.com/attribution">\xA9 Mapterhorn</a>',
|
|
2056
2056
|
contours: {
|
|
2057
2057
|
demMaxZoom: 12,
|
|
2058
|
-
demUrl: "https://tiles.mapterhorn.com/{z}/{x}/{y}.webp",
|
|
2059
2058
|
index: {
|
|
2060
2059
|
color: blueprintPalette.contour,
|
|
2061
2060
|
opacity: 0.46,
|
|
@@ -6647,7 +6646,6 @@ var siegfried = bindOfficialMapTheme(
|
|
|
6647
6646
|
attribution: 'Terrain: <a href="https://mapterhorn.com/attribution">\xA9 Mapterhorn</a>',
|
|
6648
6647
|
contours: {
|
|
6649
6648
|
demMaxZoom: 12,
|
|
6650
|
-
demUrl: "https://tiles.mapterhorn.com/{z}/{x}/{y}.webp",
|
|
6651
6649
|
index: {
|
|
6652
6650
|
color: siegfriedPalette.brown,
|
|
6653
6651
|
opacity: 0.86,
|
|
@@ -7522,15 +7520,31 @@ var soundingsTheme = defineOfficialTheme({
|
|
|
7522
7520
|
}
|
|
7523
7521
|
},
|
|
7524
7522
|
// Nautical marks use the chart symbols of this directory. They are single-colour silhouettes:
|
|
7525
|
-
// buoys
|
|
7523
|
+
// buoys, light flares and notice boards take each mark's own colour, the others print in ink.
|
|
7526
7524
|
images: {
|
|
7527
7525
|
"nautical.buoy": "soundings-buoy-pillar",
|
|
7528
7526
|
"nautical.buoy.cardinal": "soundings-buoy-cardinal",
|
|
7529
7527
|
"nautical.buoy.port": "soundings-buoy-port",
|
|
7530
7528
|
"nautical.buoy.starboard": "soundings-buoy-starboard",
|
|
7529
|
+
"nautical.distance-mark": "soundings-distance-mark",
|
|
7530
|
+
"nautical.facility": "soundings-facility",
|
|
7531
|
+
"nautical.facility.boat-hoist": "soundings-boat-hoist",
|
|
7532
|
+
"nautical.facility.boatyard": "soundings-boatyard",
|
|
7533
|
+
"nautical.facility.fuel-station": "soundings-fuel-station",
|
|
7534
|
+
"nautical.facility.pump-out": "soundings-pump-out",
|
|
7535
|
+
"nautical.facility.slipway": "soundings-slipway",
|
|
7536
|
+
"nautical.facility.visitor-berth": "soundings-visitor-berth",
|
|
7537
|
+
"nautical.facility.water-tap": "soundings-water-tap",
|
|
7531
7538
|
"nautical.harbour": "soundings-harbor",
|
|
7532
7539
|
"nautical.light": "soundings-light-flare",
|
|
7533
7540
|
"nautical.lighthouse": "soundings-lighthouse",
|
|
7541
|
+
"nautical.marina": "soundings-marina",
|
|
7542
|
+
"nautical.notice": "soundings-notice",
|
|
7543
|
+
"nautical.notice.information": "soundings-notice-information",
|
|
7544
|
+
"nautical.notice.prohibition": "soundings-notice-prohibition",
|
|
7545
|
+
"nautical.notice.recommendation": "soundings-notice-recommendation",
|
|
7546
|
+
"nautical.notice.regulation": "soundings-notice-regulation",
|
|
7547
|
+
"nautical.notice.restriction": "soundings-notice-restriction",
|
|
7534
7548
|
"nautical.port": "soundings-harbor",
|
|
7535
7549
|
"nautical.wreck": "soundings-wreck"
|
|
7536
7550
|
},
|
|
@@ -7858,11 +7872,18 @@ var soundings = bindOfficialMapTheme(
|
|
|
7858
7872
|
// printed ink. Technical magenta stays on operational areas, traffic separation and cables.
|
|
7859
7873
|
nautical: nautical({
|
|
7860
7874
|
beacons: { marker: { strokeColor: soundingsPalette.ink } },
|
|
7875
|
+
// Bridges and berths are structures, printed in the chart ink like piers.
|
|
7876
|
+
berths: { outline: { color: soundingsPalette.ink } },
|
|
7877
|
+
bridges: { outline: { color: soundingsPalette.ink } },
|
|
7861
7878
|
buoys: { icon: { haloColor: soundingsPalette.ink }, text: chartInk },
|
|
7879
|
+
distanceMarks: { icon: chartInk, text: { ...chartInk, color: soundingsPalette.inkMuted } },
|
|
7880
|
+
facilities: { icon: chartInk, text: { ...chartInk, color: soundingsPalette.inkMuted } },
|
|
7862
7881
|
harbours: { icon: chartInk, text: { ...chartInk, color: soundingsPalette.inkMuted } },
|
|
7863
7882
|
hazards: { marker: { strokeColor: soundingsPalette.ink }, text: chartInk },
|
|
7883
|
+
labels: { bridges: { text: chartInk } },
|
|
7864
7884
|
lighthouses: { icon: chartInk, text: chartInk },
|
|
7865
7885
|
lights: { text: { ...chartInk, color: soundingsPalette.inkMuted } },
|
|
7886
|
+
notices: { icon: { haloColor: soundingsPalette.water }, text: chartInk },
|
|
7866
7887
|
ports: { icon: chartInk, text: chartInk },
|
|
7867
7888
|
wrecks: { icon: chartInk, text: chartInk }
|
|
7868
7889
|
}),
|
|
@@ -10131,6 +10152,41 @@ var standardRoadCasingProfiles = {
|
|
|
10131
10152
|
};
|
|
10132
10153
|
var streetsRoadCasingProfiles = standardRoadCasingProfiles;
|
|
10133
10154
|
|
|
10155
|
+
// src/official/streets-sky.ts
|
|
10156
|
+
var skies = {
|
|
10157
|
+
day: { color: "#5C9CE6", horizon: "#DCEBF7", blend: 0.6, glow: "#FFE7B8" },
|
|
10158
|
+
dawn: { color: "#7F9FD6", horizon: "#F6D4BC", blend: 0.75, glow: "#FFC77A" },
|
|
10159
|
+
dusk: { color: "#4A4784", horizon: "#E7A3A4", blend: 0.8, glow: "#FFA552" },
|
|
10160
|
+
night: { color: "#0B1630", horizon: "#26365A", blend: 0.6, glow: "#B4645A" }
|
|
10161
|
+
};
|
|
10162
|
+
function channels(hex2) {
|
|
10163
|
+
const value = Number.parseInt(hex2.slice(1), 16);
|
|
10164
|
+
return [value >> 16, value >> 8 & 255, value & 255];
|
|
10165
|
+
}
|
|
10166
|
+
function hex(rgb) {
|
|
10167
|
+
return `#${rgb.map(
|
|
10168
|
+
(channel) => Math.max(0, Math.min(255, Math.round(channel))).toString(16).padStart(2, "0").toUpperCase()
|
|
10169
|
+
).join("")}`;
|
|
10170
|
+
}
|
|
10171
|
+
function inFamily(color, family) {
|
|
10172
|
+
const rgb = channels(color);
|
|
10173
|
+
const gray = rgb[0] * 0.2126 + rgb[1] * 0.7152 + rgb[2] * 0.0722;
|
|
10174
|
+
if (family === "monochrome") return hex([gray, gray, gray]);
|
|
10175
|
+
if (family === "faded") return hex(rgb.map((channel) => channel + (gray - channel) * 0.35));
|
|
10176
|
+
return color;
|
|
10177
|
+
}
|
|
10178
|
+
function streetsSkyTokens(preset, family) {
|
|
10179
|
+
const sky = skies[preset];
|
|
10180
|
+
return {
|
|
10181
|
+
colors: {
|
|
10182
|
+
"sky.color": inFamily(sky.color, family),
|
|
10183
|
+
"sky.horizon": inFamily(sky.horizon, family),
|
|
10184
|
+
"sky.glow": inFamily(sky.glow, family)
|
|
10185
|
+
},
|
|
10186
|
+
numbers: { "sky.horizonBlend": sky.blend }
|
|
10187
|
+
};
|
|
10188
|
+
}
|
|
10189
|
+
|
|
10134
10190
|
// src/official/streets-theme-colors.ts
|
|
10135
10191
|
var streetsSurfaceProfiles = {
|
|
10136
10192
|
"default-dawn": {
|
|
@@ -10257,7 +10313,7 @@ var streetsSurfaceProfiles = {
|
|
|
10257
10313
|
|
|
10258
10314
|
// src/official/streets-tree-colors.ts
|
|
10259
10315
|
var streetsTreeProfiles = {
|
|
10260
|
-
"default-day": { bark: "#C3D3B1", crown: "#
|
|
10316
|
+
"default-day": { bark: "#C3D3B1", crown: "#A4CFA5" },
|
|
10261
10317
|
"default-dawn": { bark: "#BCBC94", crown: "#97B37F" },
|
|
10262
10318
|
"default-dusk": { bark: "#564B43", crown: "#3D4538" },
|
|
10263
10319
|
"default-night": { bark: "#0E1D28", crown: "#0E1D24" },
|
|
@@ -10273,6 +10329,7 @@ var streetsTreeProfiles = {
|
|
|
10273
10329
|
|
|
10274
10330
|
// src/official/streets-themes.ts
|
|
10275
10331
|
var streetsLightColors = {
|
|
10332
|
+
"labels.address": "#808080",
|
|
10276
10333
|
"boundaries.admin": "#CE9298",
|
|
10277
10334
|
"boundaries.default": "#CE9298",
|
|
10278
10335
|
"boundaries.disputed": "#CE9298",
|
|
@@ -10431,15 +10488,16 @@ var streetsLightColors = {
|
|
|
10431
10488
|
"terrain.hillshade.shadow": "#727B64",
|
|
10432
10489
|
"transit.primary": "#5C74D6",
|
|
10433
10490
|
"vegetation.tree.bark": "#918878",
|
|
10434
|
-
"vegetation.tree.broadleaf.a": "#
|
|
10491
|
+
"vegetation.tree.broadleaf.a": "#77AA88",
|
|
10435
10492
|
"vegetation.tree.broadleaf.b": "#91BA8D",
|
|
10436
|
-
"vegetation.tree.broadleaf.c": "#
|
|
10437
|
-
"vegetation.tree.broadleaf.d": "#
|
|
10493
|
+
"vegetation.tree.broadleaf.c": "#A6C682",
|
|
10494
|
+
"vegetation.tree.broadleaf.d": "#AECFA2",
|
|
10438
10495
|
"vegetation.tree.conifer.a": "#729B78",
|
|
10439
10496
|
"vegetation.tree.conifer.b": "#81A880",
|
|
10440
10497
|
"vegetation.tree.conifer.c": "#91B68B"
|
|
10441
10498
|
};
|
|
10442
10499
|
var streetsDarkColors = {
|
|
10500
|
+
"labels.address": "#808080",
|
|
10443
10501
|
"boundaries.admin": "#9A6177",
|
|
10444
10502
|
"boundaries.default": "#9A6177",
|
|
10445
10503
|
"boundaries.disputed": "#9A6177",
|
|
@@ -10602,9 +10660,9 @@ var streetsDarkColors = {
|
|
|
10602
10660
|
"vegetation.tree.conifer.c": "#405348"
|
|
10603
10661
|
};
|
|
10604
10662
|
function parseStreetsColor(value) {
|
|
10605
|
-
const
|
|
10606
|
-
if (
|
|
10607
|
-
const digits =
|
|
10663
|
+
const hex2 = /^#([\da-f]{3,4}|[\da-f]{6}|[\da-f]{8})$/i.exec(value);
|
|
10664
|
+
if (hex2) {
|
|
10665
|
+
const digits = hex2[1];
|
|
10608
10666
|
const expanded = digits.length < 5 ? [...digits].map((digit) => digit + digit).join("") : digits;
|
|
10609
10667
|
return {
|
|
10610
10668
|
r: Number.parseInt(expanded.slice(0, 2), 16),
|
|
@@ -10631,8 +10689,8 @@ function formatStreetsColor({ a, b, g, r }, format) {
|
|
|
10631
10689
|
if (format.startsWith("rgba")) {
|
|
10632
10690
|
return `rgba(${channel(r)}, ${channel(g)}, ${channel(b)}, ${Number(a.toFixed(3))})`;
|
|
10633
10691
|
}
|
|
10634
|
-
const
|
|
10635
|
-
return `#${
|
|
10692
|
+
const hex2 = (value) => channel(value).toString(16).padStart(2, "0").toUpperCase();
|
|
10693
|
+
return `#${hex2(r)}${hex2(g)}${hex2(b)}${format.length === 9 ? hex2(a * 255) : ""}`;
|
|
10636
10694
|
}
|
|
10637
10695
|
function adjustStreetsColors(colors, transform) {
|
|
10638
10696
|
return Object.fromEntries(
|
|
@@ -10732,7 +10790,8 @@ function streetsPaletteColors(preset, colorTheme) {
|
|
|
10732
10790
|
...calibratedStreetsColors(preset, colorTheme),
|
|
10733
10791
|
...streetsCartographyColors(colorTheme, preset),
|
|
10734
10792
|
"buildings.floodLight": !isDarkStreetsPreset(preset) ? "#FFFFFF" : colorTheme === "monochrome" ? "#E5E5E5" : colorTheme === "faded" ? "#F8E4C4" : "#F5CFA8",
|
|
10735
|
-
...streetsModelLighting(preset, colorTheme).colors
|
|
10793
|
+
...streetsModelLighting(preset, colorTheme).colors,
|
|
10794
|
+
...streetsSkyTokens(preset, colorTheme).colors
|
|
10736
10795
|
};
|
|
10737
10796
|
}
|
|
10738
10797
|
function streetsLightingNumbers(preset, colorTheme) {
|
|
@@ -10742,13 +10801,14 @@ function streetsLightingNumbers(preset, colorTheme) {
|
|
|
10742
10801
|
// Light colours already include the Faded lookup table; lamp activation uses the
|
|
10743
10802
|
// corresponding untransformed brightness, independently of that appearance change.
|
|
10744
10803
|
"buildings.floodLight.brightnessScale": colorTheme === "faded" ? { day: 1, dawn: 0.9203658119566795, dusk: 0.47333738050439994, night: 0.42688225390661877 }[preset] : 1,
|
|
10745
|
-
...streetsModelLighting(preset, colorTheme).numbers
|
|
10804
|
+
...streetsModelLighting(preset, colorTheme).numbers,
|
|
10805
|
+
...streetsSkyTokens(preset, colorTheme).numbers
|
|
10746
10806
|
};
|
|
10747
10807
|
}
|
|
10748
|
-
var
|
|
10749
|
-
// DIN Pro Medium has much lighter strokes than Noto Sans Bold. Of the
|
|
10750
|
-
// hosted Noto faces, Regular is the closer match for navigation and POIs.
|
|
10808
|
+
var streetsFonts2 = {
|
|
10751
10809
|
default: "Noto Sans Regular",
|
|
10810
|
+
navigation: "DINish Medium",
|
|
10811
|
+
shield: "DINish Bold",
|
|
10752
10812
|
places: "Noto Sans Bold",
|
|
10753
10813
|
regular: "Noto Sans Regular",
|
|
10754
10814
|
water: "Noto Sans Italic"
|
|
@@ -10778,7 +10838,7 @@ var streetsLightTheme = defineTheme3({
|
|
|
10778
10838
|
tokens: {
|
|
10779
10839
|
color: streetsPaletteColors("day", "default"),
|
|
10780
10840
|
number: streetsLightingNumbers("day", "default"),
|
|
10781
|
-
font:
|
|
10841
|
+
font: streetsFonts2,
|
|
10782
10842
|
image: { ...streetsImages, ...streetsPoiImageTokens("light") }
|
|
10783
10843
|
},
|
|
10784
10844
|
typography: {
|
|
@@ -10804,7 +10864,7 @@ var streetsDarkTheme = defineTheme3({
|
|
|
10804
10864
|
tokens: {
|
|
10805
10865
|
color: streetsPaletteColors("night", "default"),
|
|
10806
10866
|
number: streetsLightingNumbers("night", "default"),
|
|
10807
|
-
font:
|
|
10867
|
+
font: streetsFonts2,
|
|
10808
10868
|
image: {
|
|
10809
10869
|
...streetsImages,
|
|
10810
10870
|
...streetsPoiImageTokens("dark"),
|
|
@@ -10891,6 +10951,7 @@ var streetsVisual = {
|
|
|
10891
10951
|
waterway: token7.color("hydro.waterway")
|
|
10892
10952
|
},
|
|
10893
10953
|
label: {
|
|
10954
|
+
address: token7.color("labels.address"),
|
|
10894
10955
|
aerodrome: token7.color("labels.aerodrome"),
|
|
10895
10956
|
country: token7.color("labels.country"),
|
|
10896
10957
|
ferry: token7.color("labels.ferry"),
|
|
@@ -11044,6 +11105,8 @@ var streetsVisual = {
|
|
|
11044
11105
|
},
|
|
11045
11106
|
font: {
|
|
11046
11107
|
default: token7.font("default"),
|
|
11108
|
+
navigation: token7.font("navigation"),
|
|
11109
|
+
shield: token7.font("shield"),
|
|
11047
11110
|
places: token7.font("places"),
|
|
11048
11111
|
regular: token7.font("regular"),
|
|
11049
11112
|
water: token7.font("water")
|
|
@@ -11249,12 +11312,14 @@ var streetsTrees = withRenderStack9(
|
|
|
11249
11312
|
hedgeColors: [token8.color("landcover.hedgeShade"), token8.color("landcover.hedge")],
|
|
11250
11313
|
crownScale: 1,
|
|
11251
11314
|
heightScale: 1,
|
|
11252
|
-
|
|
11315
|
+
minimumHeight: 8,
|
|
11316
|
+
materialVariation: 1,
|
|
11317
|
+
finish: "smooth",
|
|
11253
11318
|
edges: 0,
|
|
11254
11319
|
forms: {
|
|
11255
|
-
round: { models: ["streets-tree-round"] },
|
|
11320
|
+
round: { models: ["streets-tree-round", "streets-tree-open"] },
|
|
11256
11321
|
open: { models: ["streets-tree-open"] },
|
|
11257
|
-
tall: { models: ["streets-tree-tall"] },
|
|
11322
|
+
tall: { models: ["streets-tree-tall", "streets-tree-open"] },
|
|
11258
11323
|
conifer: { models: ["streets-tree-conifer"] },
|
|
11259
11324
|
columnar: { models: ["streets-tree-columnar"] },
|
|
11260
11325
|
palm: { models: ["streets-tree-palm-feather", "streets-tree-palm-fan"] }
|
|
@@ -11427,7 +11492,8 @@ function streetsPoiStyle(category) {
|
|
|
11427
11492
|
size: 1
|
|
11428
11493
|
},
|
|
11429
11494
|
text: {
|
|
11430
|
-
font: streetsVisual.font.
|
|
11495
|
+
font: streetsVisual.font.navigation,
|
|
11496
|
+
fallbacks: [streetsVisual.font.regular],
|
|
11431
11497
|
haloWidth: 1,
|
|
11432
11498
|
haloBlur: 0,
|
|
11433
11499
|
letterSpacing: 0.01,
|
|
@@ -12001,7 +12067,8 @@ function streetsBuildingRenderStack() {
|
|
|
12001
12067
|
}
|
|
12002
12068
|
}),
|
|
12003
12069
|
extrusion: renderPass10({
|
|
12004
|
-
|
|
12070
|
+
// Keep raised geometry after the ground names, which already cover flat footprints.
|
|
12071
|
+
placement: "above-buildings",
|
|
12005
12072
|
feature: "building",
|
|
12006
12073
|
renderer: "extrusion",
|
|
12007
12074
|
selector: visibleBuilding3dSelector,
|
|
@@ -12480,17 +12547,44 @@ function roadLabelStyle(kind, minZoom) {
|
|
|
12480
12547
|
return {
|
|
12481
12548
|
placement: "line",
|
|
12482
12549
|
minZoom,
|
|
12483
|
-
|
|
12484
|
-
|
|
12550
|
+
// Resolve dense parallel streets by road hierarchy, not incidental tile order.
|
|
12551
|
+
// All classes share this expression so the compiler retains one collision network.
|
|
12552
|
+
priority: expr12.match(
|
|
12553
|
+
expr12.coalesce(expr12.get(field11("class")), "minor"),
|
|
12554
|
+
[
|
|
12555
|
+
{ labels: ["motorway", "motorway_construction"], value: 6 },
|
|
12556
|
+
{ labels: ["trunk", "trunk_construction"], value: 5 },
|
|
12557
|
+
{ labels: ["primary", "primary_construction"], value: 4 },
|
|
12558
|
+
{ labels: ["secondary", "secondary_construction"], value: 3 },
|
|
12559
|
+
{ labels: ["tertiary", "tertiary_construction"], value: 2 },
|
|
12560
|
+
{ labels: ["minor", "minor_construction"], value: 1 }
|
|
12561
|
+
],
|
|
12562
|
+
0
|
|
12563
|
+
),
|
|
12564
|
+
// World name geometry is split into more short segments at street detail.
|
|
12565
|
+
// Increase repeat distance gently without thinning the overview network.
|
|
12566
|
+
spacing: zoom10.linear([
|
|
12567
|
+
[13, 250],
|
|
12568
|
+
[15, 300],
|
|
12569
|
+
[17, 400],
|
|
12570
|
+
[19, 450]
|
|
12571
|
+
]),
|
|
12485
12572
|
text: {
|
|
12486
12573
|
color: streetsVisual.label.road,
|
|
12487
|
-
font: streetsVisual.font.
|
|
12574
|
+
font: streetsVisual.font.navigation,
|
|
12575
|
+
fallbacks: [streetsVisual.font.regular],
|
|
12488
12576
|
haloColor: streetsVisual.label.roadHalo,
|
|
12489
12577
|
haloWidth: 1,
|
|
12490
12578
|
letterSpacing: path || pedestrian ? 0.01 : 0.15,
|
|
12491
12579
|
maxAngle: 30,
|
|
12492
|
-
padding
|
|
12493
|
-
|
|
12580
|
+
// Screen-space breathing room at city overview. Restore normal padding by z14
|
|
12581
|
+
// so the same policy does not suppress useful names on the neighbourhood view.
|
|
12582
|
+
padding: zoom10.linear([
|
|
12583
|
+
[13, 5],
|
|
12584
|
+
[14, 1]
|
|
12585
|
+
]),
|
|
12586
|
+
// Follow the road's bearing while retaining readable glyph height in perspective.
|
|
12587
|
+
pitchAlignment: "viewport",
|
|
12494
12588
|
rotationAlignment: "map",
|
|
12495
12589
|
size: zoom10.linear([
|
|
12496
12590
|
[10, startSize],
|
|
@@ -12505,11 +12599,7 @@ var streets = bindOfficialMapTheme(
|
|
|
12505
12599
|
id: "streets",
|
|
12506
12600
|
version: 1,
|
|
12507
12601
|
name: "Streets",
|
|
12508
|
-
|
|
12509
|
-
kind: "url",
|
|
12510
|
-
url: "https://api.tileflow.dev/base/33d4de5e8086d9d629d67d3f39fedb87e23686c4c1ac653c27e2a52aee9d00b3/glyphs/{fontstack}/{range}.pbf",
|
|
12511
|
-
fontStacks: ["Noto Sans Regular", "Noto Sans Bold", "Noto Sans Italic"]
|
|
12512
|
-
},
|
|
12602
|
+
fonts: [streetsFonts],
|
|
12513
12603
|
themes: streetsThemes,
|
|
12514
12604
|
timeOfDay: {
|
|
12515
12605
|
light: { day: "light", dawn: "dawn", dusk: "dusk", night: "dark" },
|
|
@@ -12525,6 +12615,14 @@ var streets = bindOfficialMapTheme(
|
|
|
12525
12615
|
systemThemes: { light: "light", dark: "dark" },
|
|
12526
12616
|
projection: "globe",
|
|
12527
12617
|
// 'globe' | 'mercator'. Globe becomes planar at street zooms.
|
|
12618
|
+
// Each theme paints the sky seen when the camera tilts up the street; night shows stars.
|
|
12619
|
+
sky: {
|
|
12620
|
+
color: token9.color("sky.color"),
|
|
12621
|
+
horizonColor: token9.color("sky.horizon"),
|
|
12622
|
+
horizonBlend: token9.number("sky.horizonBlend"),
|
|
12623
|
+
glowColor: token9.color("sky.glow"),
|
|
12624
|
+
starIntensity: 0.6
|
|
12625
|
+
},
|
|
12528
12626
|
data: {
|
|
12529
12627
|
generation: "v1",
|
|
12530
12628
|
selection: { kind: "current", product: "world-v1" },
|
|
@@ -12556,14 +12654,14 @@ var streets = bindOfficialMapTheme(
|
|
|
12556
12654
|
// Optional keys: addresses, aeroways, boundaries, buildings, labels, land,
|
|
12557
12655
|
// landforms, poi, roads, transit, vegetation, water. Object order never
|
|
12558
12656
|
// controls layer order.
|
|
12559
|
-
//
|
|
12560
|
-
// labels carry the useful navigation hierarchy without close-zoom numeric noise.
|
|
12657
|
+
// House numbers arrive at close zooms and yield in the distance when tilted.
|
|
12561
12658
|
addresses: addresses4({
|
|
12562
12659
|
labels: {
|
|
12563
12660
|
minZoom: 17,
|
|
12564
12661
|
text: {
|
|
12565
|
-
font: streetsVisual.font.
|
|
12566
|
-
|
|
12662
|
+
font: streetsVisual.font.navigation,
|
|
12663
|
+
fallbacks: [streetsVisual.font.regular],
|
|
12664
|
+
color: streetsVisual.label.address,
|
|
12567
12665
|
haloColor: streetsVisual.label.placeHalo,
|
|
12568
12666
|
haloWidth: 1,
|
|
12569
12667
|
maxWidth: 10,
|
|
@@ -13406,10 +13504,14 @@ var streets = bindOfficialMapTheme(
|
|
|
13406
13504
|
// 'auto' | 'local' | 'en' | another language field suffix.
|
|
13407
13505
|
places: "all",
|
|
13408
13506
|
// 'none' | 'major' | 'all'.
|
|
13507
|
+
// Street names yield to foreground destinations and are hidden by 3D buildings.
|
|
13508
|
+
// Their viewport-aligned lettering stays readable at an oblique camera angle.
|
|
13409
13509
|
roadPlacement: "ground",
|
|
13510
|
+
roadNameFormat: "compact",
|
|
13511
|
+
roadGrouping: "network",
|
|
13410
13512
|
roads: "all",
|
|
13411
13513
|
// Preserve Streets' selection while Core owns class aliases, language
|
|
13412
|
-
// fallback
|
|
13514
|
+
// fallback and collision ordering.
|
|
13413
13515
|
roadClasses: [
|
|
13414
13516
|
"motorway",
|
|
13415
13517
|
"trunk",
|
|
@@ -13418,6 +13520,7 @@ var streets = bindOfficialMapTheme(
|
|
|
13418
13520
|
"tertiary",
|
|
13419
13521
|
"minor",
|
|
13420
13522
|
"service",
|
|
13523
|
+
"track",
|
|
13421
13524
|
"pathway",
|
|
13422
13525
|
"footway",
|
|
13423
13526
|
"cycleway",
|
|
@@ -13439,6 +13542,7 @@ var streets = bindOfficialMapTheme(
|
|
|
13439
13542
|
tertiary: roadLabelStyle("major", 13),
|
|
13440
13543
|
minor: roadLabelStyle("street", 13),
|
|
13441
13544
|
service: roadLabelStyle("service", 15),
|
|
13545
|
+
track: roadLabelStyle("service", 15),
|
|
13442
13546
|
pathway: roadLabelStyle("path", 15),
|
|
13443
13547
|
footway: roadLabelStyle("path", 15),
|
|
13444
13548
|
cycleway: roadLabelStyle("path", 15),
|
|
@@ -13782,10 +13886,11 @@ var streets = bindOfficialMapTheme(
|
|
|
13782
13886
|
placement: "point",
|
|
13783
13887
|
text: {
|
|
13784
13888
|
color: streetsVisual.label.road,
|
|
13785
|
-
font: streetsVisual.font.
|
|
13889
|
+
font: streetsVisual.font.shield,
|
|
13890
|
+
fallbacks: [streetsVisual.font.regular],
|
|
13786
13891
|
haloColor: streetsDetailPalette.halo,
|
|
13787
13892
|
haloWidth: 1,
|
|
13788
|
-
size:
|
|
13893
|
+
size: 9
|
|
13789
13894
|
}
|
|
13790
13895
|
},
|
|
13791
13896
|
shields: {
|
|
@@ -13803,7 +13908,8 @@ var streets = bindOfficialMapTheme(
|
|
|
13803
13908
|
},
|
|
13804
13909
|
text: {
|
|
13805
13910
|
color: streetsVisual.label.shieldDark,
|
|
13806
|
-
font: streetsVisual.font.
|
|
13911
|
+
font: streetsVisual.font.shield,
|
|
13912
|
+
fallbacks: [streetsVisual.font.regular],
|
|
13807
13913
|
haloWidth: 0,
|
|
13808
13914
|
letterSpacing: 0.05,
|
|
13809
13915
|
maxAngle: 38,
|
|
@@ -13811,7 +13917,7 @@ var streets = bindOfficialMapTheme(
|
|
|
13811
13917
|
padding: 2,
|
|
13812
13918
|
pitchAlignment: "viewport",
|
|
13813
13919
|
rotationAlignment: "viewport",
|
|
13814
|
-
size:
|
|
13920
|
+
size: 9
|
|
13815
13921
|
}
|
|
13816
13922
|
},
|
|
13817
13923
|
overview: {
|
|
@@ -13819,10 +13925,12 @@ var streets = bindOfficialMapTheme(
|
|
|
13819
13925
|
minZoom: 6
|
|
13820
13926
|
},
|
|
13821
13927
|
detail: {
|
|
13822
|
-
//
|
|
13823
|
-
//
|
|
13928
|
+
// World splits route lines more often than the reference source. A shorter
|
|
13929
|
+
// interval keeps route references available in regional views; collision
|
|
13930
|
+
// still suppresses adjacent shields, and street-scale repetition stays sparse.
|
|
13824
13931
|
spacing: zoom10.linear([
|
|
13825
|
-
[11,
|
|
13932
|
+
[11, 220],
|
|
13933
|
+
[13, 300],
|
|
13826
13934
|
[14, 600]
|
|
13827
13935
|
])
|
|
13828
13936
|
},
|
|
@@ -13938,9 +14046,8 @@ var streets = bindOfficialMapTheme(
|
|
|
13938
14046
|
streetsLabelRenderStack()
|
|
13939
14047
|
),
|
|
13940
14048
|
poi: poi4({
|
|
13941
|
-
// World
|
|
13942
|
-
//
|
|
13943
|
-
// order, so collision keeps the most relevant places whatever their category.
|
|
14049
|
+
// Keep World's importance order while reserving room for navigation and landmarks.
|
|
14050
|
+
// Everyday businesses enter progressively; tilted views also limit distant labels.
|
|
13944
14051
|
categories: [
|
|
13945
14052
|
"transport",
|
|
13946
14053
|
"food-drink",
|
|
@@ -13960,7 +14067,14 @@ var streets = bindOfficialMapTheme(
|
|
|
13960
14067
|
// A uniform grey treatment suppresses a meaningful amount of chroma
|
|
13961
14068
|
// and makes the whole light map read as if a pale overlay sat above it.
|
|
13962
14069
|
color: "category",
|
|
13963
|
-
density:
|
|
14070
|
+
density: 2,
|
|
14071
|
+
detailZoom: 18,
|
|
14072
|
+
densityByCategory: {
|
|
14073
|
+
lodging: 1,
|
|
14074
|
+
"park-nature": 3,
|
|
14075
|
+
religion: 1,
|
|
14076
|
+
transport: 3
|
|
14077
|
+
},
|
|
13964
14078
|
icons: true,
|
|
13965
14079
|
labels: true,
|
|
13966
14080
|
placement: {
|
|
@@ -13969,8 +14083,8 @@ var streets = bindOfficialMapTheme(
|
|
|
13969
14083
|
coupleIconAndLabel: true,
|
|
13970
14084
|
iconPadding: 3,
|
|
13971
14085
|
order: "importance",
|
|
13972
|
-
//
|
|
13973
|
-
//
|
|
14086
|
+
// Landmarks retain their priority. Ground street names yield to destinations;
|
|
14087
|
+
// the navigation policy keeps the city and district hierarchy above them.
|
|
13974
14088
|
prominentRank: 1,
|
|
13975
14089
|
textPadding: 3
|
|
13976
14090
|
},
|
|
@@ -14025,6 +14139,7 @@ export {
|
|
|
14025
14139
|
soundings2 as soundings,
|
|
14026
14140
|
soundingsIcons,
|
|
14027
14141
|
streets2 as streets,
|
|
14142
|
+
streetsFonts,
|
|
14028
14143
|
streetsIcons,
|
|
14029
14144
|
streetsModels,
|
|
14030
14145
|
streetsThemes
|
|
@@ -109,11 +109,14 @@ fallback traced from broad GEBCO band polygons until native contour geometry is
|
|
|
109
109
|
show the absolute `min_depth` value, not an inferred range or vessel-specific safety contour.
|
|
110
110
|
Ferries are ordinary World context. Navigation marks come from `tileflow-nautical`: the theme's
|
|
111
111
|
`nautical.*` image tokens select the Soundings chart symbols for buoys (port can, starboard cone,
|
|
112
|
-
cardinal double cone, and a pillar for other buoys), lights, lighthouses, wrecks, harbours,
|
|
113
|
-
ports
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
112
|
+
cardinal double cone, and a pillar for other buoys), lights, lighthouses, wrecks, harbours, marinas,
|
|
113
|
+
ports, inland notice boards by function, distance marks, and small-craft facilities. Buoys, light
|
|
114
|
+
flares, and notice boards take each mark's own colour from the data; beacons stay small coloured
|
|
115
|
+
dots, rocks are chart crosses and stars, and the other symbols are printed in the chart ink. Light
|
|
116
|
+
flares flash in their rhythm in browser maps. Bridges and berths are drawn as ink structures with
|
|
117
|
+
their clearances, and marinas and harbours as light outlines. Technical magenta remains reserved for
|
|
118
|
+
operational overlays: restricted, military, anchorage, and traffic-separation areas,
|
|
119
|
+
traffic-separation lines, and submarine and overhead cables. Coverage is
|
|
117
120
|
a faint tint before marks appear. The map shows a "Not for navigation" notice wherever it is
|
|
118
121
|
displayed. Soundings is reference cartography and is not a navigation product.
|
|
119
122
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tileflow/maps",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.14",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"description": "Official themed Streets, Baedeker, Cívica, 1777, Siegfried, Soundings, and Blueprint maps for Tileflow.",
|
|
6
6
|
"type": "module",
|
|
@@ -52,12 +52,12 @@
|
|
|
52
52
|
"access": "public"
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
|
-
"@tileflow/core": ">=0.1.0-alpha.
|
|
55
|
+
"@tileflow/core": ">=0.1.0-alpha.40 <0.1.0-beta.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@maplibre/maplibre-gl-style-spec": "24.8.5",
|
|
59
59
|
"@maplibre/maplibre-gl-style-spec-v6": "npm:@maplibre/maplibre-gl-style-spec@26.4.4",
|
|
60
|
-
"@tileflow/core": "0.1.0-alpha.
|
|
60
|
+
"@tileflow/core": "0.1.0-alpha.40"
|
|
61
61
|
},
|
|
62
62
|
"scripts": {
|
|
63
63
|
"build": "tsup src/index.ts --format esm --dts --clean --no-splitting",
|