24 lines
542 B
JavaScript
24 lines
542 B
JavaScript
export default class SvgMapBulder{
|
|
let WellsRenderer = {
|
|
// [{x,y}]
|
|
heads(wells, r, style) {
|
|
return wells.map((w) => SvgNodes.circle(r).set_style(style).move(w.x, w.y));
|
|
},
|
|
|
|
// [{x,y,name}]
|
|
names(wells, style, shift) {
|
|
return wells.map((w) =>
|
|
SvgNodes.text(w.name)
|
|
.set_style(style)
|
|
.move(w.x + shift.x, w.y + shift.y)
|
|
);
|
|
},
|
|
|
|
// {x,y,ring[1,2,3,4,5]}
|
|
ring(x, y, r0, r1, a0, a1, style) {
|
|
return SvgNodes.ring_sector(r0, r1, a0, a1).move(x, y).set_style(style);
|
|
},
|
|
};
|
|
|
|
|
|
} |