Skip to content

Commit

Permalink
remove redundant prop
Browse files Browse the repository at this point in the history
  • Loading branch information
t0rbik committed Nov 21, 2024
1 parent fa88b0e commit 68b1c18
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/components/vaults/row/AprHistoricalChart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ interface AreaProps {
height: number;
margin?: { top: number; right: number; bottom: number; left: number };
data: AprHistoryItem[];
selectedTimeRange?: "1m" | "6m" | "1y";
}

/** A D3-like Tick Formatter for consistent values for date. */
Expand Down Expand Up @@ -57,7 +56,6 @@ const AprHistoricalGraph = ({
height,
margin = { top: 20, right: 10, bottom: 20, left: 40 },
data,
selectedTimeRange = "1m",
}: AreaProps) => {
const { darkMode } = useTheme();

Expand All @@ -73,7 +71,6 @@ const AprHistoricalGraph = ({
const innerWidth = width - margin.left - margin.right;
const innerHeight = height - margin.top - margin.bottom;

const xAxisNumTicks = selectedTimeRange !== "6m" ? 3 : 4;
const dateScale = useMemo(
() =>
scaleUtc({
Expand Down Expand Up @@ -185,7 +182,7 @@ const AprHistoricalGraph = ({
top={innerHeight - margin.bottom / 4}
scale={dateScale}
strokeWidth={0}
numTicks={xAxisNumTicks}
numTicks={3}
tickFormat={formatDate}
tickStroke={darkMode ? "#979BA2" : "#68645d"}
tickLabelProps={{
Expand Down

0 comments on commit 68b1c18

Please sign in to comment.