task done

This commit is contained in:
=
2026-04-10 14:33:23 +10:00
parent 838fa29509
commit 4f11081420
6 changed files with 61 additions and 61 deletions

View File

@@ -129,22 +129,9 @@ const ChartDraw = (props) => {
};
// вычисляем ширину и высоту области для вывода графиков
const boundsWidth = width - margin.left - margin.right;
const boundsHeight = height - margin.top - margin.bottom;
useEffect(() => {
if(boundsWidth<0||boundsHeight<0){
return;
}
const svg = d3.select(chartRef.current);
// выводим прямоугольник,
svg
.append("rect")
.attr("x", margin.left)
.attr("y", margin.top)
.attr("width", boundsWidth)
.attr("height", boundsHeight)
.style("fill", "lightgrey");
// console.log(props)
drawGraph(props.data,props.ox,props.minMax[0],props.minMax[1],Number(props.graphType))
});