注释调试输出

This commit is contained in:
JIANG
2026-01-29 11:43:44 +08:00
parent 5cb2d17be1
commit c28325e997

View File

@@ -344,11 +344,11 @@ const Timeline: React.FC<TimelineProps> = ({
colorCases.push(["<=", ["get", "healthRisk"], breakValue], colorStr); colorCases.push(["<=", ["get", "healthRisk"], breakValue], colorStr);
widthCases.push(["<=", ["get", "healthRisk"], breakValue], width); widthCases.push(["<=", ["get", "healthRisk"], breakValue], width);
}); });
console.log( // console.log(
`应用健康风险样式,年份: ${currentYear}, 分段: ${breaks.length}`, // `应用健康风险样式,年份: ${currentYear}, 分段: ${breaks.length}`,
); // );
console.log("颜色表达式:", colorCases); // console.log("颜色表达式:", colorCases);
console.log("宽度表达式:", widthCases); // console.log("宽度表达式:", widthCases);
// 应用样式到图层 // 应用样式到图层
pipeLayer.setStyle({ pipeLayer.setStyle({
"stroke-color": ["case", ...colorCases, "rgba(128, 128, 128, 1)"], "stroke-color": ["case", ...colorCases, "rgba(128, 128, 128, 1)"],