我刚刚将法语rivers_lines 添加到我的D3js 生成的SVG 中。它现在显示如下结果:
我需要在没有人工制品的情况下保持河流线。
数据:由弧组成的 topojson。
CSS 代码:
.rivers {
fill: none;
fill-opacity: .1;
stroke-width:1px;
stroke: #C6ECFF;
}
一些颜色和不透明度接近于零的相同结果:
fill: #FF0000;
fill-opacity: .1;
D3 代码:
rivers = topojson.feature(fra, fra.objects.rivers),
//Append rivers
svg.append("path")
.datum(rivers)
.attr("d", path)
svg.selectAll(".rivers")
.data(topojson.feature(fra, fra.objects.rivers).features)
.enter().append("path")
.attr("class", function(d) { return "rivers"; })
.attr("data-name-en", function(d) { return d.properties.name; })
.attr("d", path);
我的完整小提琴暂时在这里。
如何解决?