Skip to main content

logoTickLabel

import { BarPlot } from "@mui/x-charts/BarChart";
import { ChartsContainer } from "@mui/x-charts/ChartsContainer";
import { ChartsXAxis } from "@mui/x-charts/ChartsXAxis";
import { ChartsYAxis } from "@mui/x-charts/ChartsYAxis";
import { loadLeague } from "@sportsdataverse/sdvplot";
import { logoTickLabel } from "@sportsdataverse/sdvplot/mui";

await loadLeague("nfl");
const teams = ["KC", "BUF", "BAL"];
<ChartsContainer
width={400}
height={260}
xAxis={[{ id: "teams", scaleType: "band", data: teams, height: 40 }]}
yAxis={[{ id: "wins" }]}
series={[{ type: "bar", data: [15, 13, 12] }]}
>
<BarPlot />
<ChartsXAxis axisId="teams" slots={{ axisTickLabel: logoTickLabel({ league: "nfl", size: 28 }) }} />
<ChartsYAxis axisId="wins" />
</ChartsContainer>;

Tags: docstring · logoTickLabel. All sdvplot examples.