Skip to content

Commit

Permalink
ac-bar-fix-tl
Browse files Browse the repository at this point in the history
  • Loading branch information
Kinatzo committed Oct 7, 2024
1 parent 7a35c6d commit 173c664
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/abstract-chart/src/chart.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1073,9 +1073,9 @@ export function generateBars(xMin: number, xMax: number, yMin: number, yMax: num
const [tl, middle, br] =
bars.direction === "x"
? [
AI.createPoint(b.min ?? xMinValue, barPos - bars.width / 2),
AI.createPoint(b.min ?? xMinValue, barPos + bars.width / 2),
AI.createPoint((b.max - (b.min ?? xMinValue)) / 2, barPos),
AI.createPoint(b.max, barPos + bars.width / 2),
AI.createPoint(b.max, barPos - bars.width / 2),
]
: [
AI.createPoint(barPos - bars.width / 2, b.max),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ function generateBarChart(): AC.Chart {
{ ...chartBase, position: 4, bars: [{ max: 2, color: AI.fromArgb(255, 255, 0, 0) }] },
{ ...chartBase, position: 6, bars: [{ max: 4, color: AI.fromArgb(255, 255, 0, 0) }] },
{ ...chartBase, position: 7, bars: [{ max: 5, color: AI.fromArgb(255, 255, 0, 0) }] },
{ ...chartBase, position: 9, bars: [{ max: 8, color: AI.fromArgb(255, 255, 0, 0) }] },
{ ...chartBase, position: 10, bars: [{ max: 8, color: AI.fromArgb(255, 255, 0, 0) }] },
],
xAxisesBottom: [xAxis],
xAxisesTop: [{ type: "linear", min: 0, max: 8, label: "", axisColor: { r: 0, b: 0, g: 0, a: 255 }, noTicks: true }],
Expand Down

0 comments on commit 173c664

Please sign in to comment.