fix: bind Kyushu web style to current release

This commit is contained in:
OpenAI Codex
2026-09-21 15:33:56 +08:00
parent 91bd41754d
commit 79b8d6cd5b
3 changed files with 14 additions and 11 deletions

View File

@@ -44,7 +44,7 @@
<body>
<div id="toolbar">
<strong>九州 S-52 PBF 对比</strong>
<span class="meta">左:Production v4 / 0.4.12 本地 PBF 右:extentfix 原始数据源</span>
<span class="meta">左:当前 Production 本地 PBF 右:extentfix 原始数据源</span>
<label><input id="sync-toggle" type="checkbox" checked />同步视图</label>
<button id="reset-btn" type="button">重置九州</button>
<button id="debug-toggle-btn" type="button">调试</button>
@@ -63,7 +63,7 @@
<section class="pane" id="left-pane">
<div id="left-map" class="map"></div>
<canvas id="left-ca-overlay" class="ca-overlay" aria-hidden="true"></canvas>
<div class="pane-title"><b>左:九州 Production v4 / 0.4.12</b><span id="left-state" class="state">等待参考 style…</span></div>
<div class="pane-title"><b>左:九州当前 Production</b><span id="left-state" class="state">等待参考 style…</span></div>
<div id="left-inspector" class="inspector empty">点击任一侧海图,对比同一位置的 Feature。</div>
<div class="divider-label">LOCAL</div>
</section>
@@ -656,8 +656,8 @@ function cloneReferenceForLocal(referenceStyle){
source.minzoom=5;
source.maxzoom=12;
source.bounds=[128.0,29.5,132.5,34.8];
source.attribution="CM95 九州 S-52 Production 0.4.12 OpenCPN coverage";
style.name=(style.name || "NavSea") + " / Kyushu Production v4 / 0.4.12";
source.attribution="CM95 九州当前 S-52 Production";
style.name=(style.name || "NavSea") + " / Kyushu current Production";
return style;
}
@@ -670,7 +670,7 @@ function prepareS52Style(raw){
source.minzoom=5;
source.maxzoom=12;
source.bounds=[128.0,29.5,132.5,34.8];
source.attribution="CM95 九州 S-52 Production 0.4.12 OpenCPN coverage";
source.attribution="CM95 九州当前 S-52 Production";
style.sprite=location.origin + "/s52/sprite";
if(referenceStyleTemplate && referenceStyleTemplate.glyphs){
style.glyphs=referenceStyleTemplate.glyphs;
@@ -728,9 +728,9 @@ leftMap.on("style.load",function(){
const sources=Object.keys((leftMap.getStyle() || {}).sources || {});
if(sources.includes("cm95")){
installRuntimePreviewLayers(leftMap);
setState(leftState,"Production v4 / 0.4.12 / S-52 style" + (debugRuntimePreview.checked ? " + runtime preview" : ""),"ok");
setState(leftState,"当前 Production / S-52 style" + (debugRuntimePreview.checked ? " + runtime preview" : ""),"ok");
}else if(sources.includes("navsea_delivery")){
setState(leftState,"Production v4 / 0.4.12 / extentfix style","ok");
setState(leftState,"当前 Production / extentfix style","ok");
}
applyDebugStyles();
refreshLightArcFeatures();
@@ -791,7 +791,7 @@ debugLeftS52.addEventListener("change",function(){
debugRuntimePreview.addEventListener("change",function(){
if(leftMap.getSource("cm95")){
installRuntimePreviewLayers(leftMap);
setState(leftState,"Production v4 / 0.4.12 / S-52 style" + (debugRuntimePreview.checked ? " + runtime preview" : ""),"ok");
setState(leftState,"当前 Production / S-52 style" + (debugRuntimePreview.checked ? " + runtime preview" : ""),"ok");
applyDebugStyles();
}
});