SIGN IN SIGN UP
mermaid-js / mermaid UNCLAIMED

Generation of diagrams like flowcharts or sequence diagrams from text in a similar manner as markdown

0 0 163 TypeScript

fix(xychart): truncate plot data to match x-axis category count

When a band x-axis has N categories but a bar/line plot provides M > N data
points, the extra points rendered into unlabeled chart space. The Y-axis
range was also distorted by the orphaned values.

This truncates the data array to match the category count before computing
the Y-axis range, preventing both orphaned bars/lines and scale distortion.

Resolves #7650
D
Dharya-dev committed
8dcdce40ee091aafd546aa842aca8b4da1e49c1b
Parent: f472f50