Skip to content

Commit e531ab1

Browse files
committed
fix: remove unused banner prop
1 parent 15f7e25 commit e531ab1

File tree

3 files changed

+0
-11
lines changed

3 files changed

+0
-11
lines changed

example/app/index.tsx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ import { useCallback, useState } from "react";
33
import { Button, StyleSheet, Text, View } from "react-native";
44
import { useSafeAreaInsets } from "react-native-safe-area-context";
55

6-
import { Banner } from "../components/Banner";
7-
86
const generateRandomData = (): [number, number][] => {
97
return Array.from({ length: 30 }, (_, i) => [i, Math.random() * 2000]);
108
};
@@ -32,7 +30,6 @@ export default () => {
3230
<LineChart
3331
points={data}
3432
style={styles.chart}
35-
BannerComponent={Banner}
3633
TopAxisLabel={AxisLabel}
3734
BottomAxisLabel={AxisLabel}
3835
/>

src/components/LineChart/Banner.tsx

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/components/LineChart/index.tsx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { GestureDetector } from "react-native-gesture-handler";
55
import { useDerivedValue, useSharedValue } from "react-native-reanimated";
66

77
import { AxisLabelComponentProps, AxisLabelContainer } from "./AxisLabel";
8-
import type { BannerComponentProps } from "./Banner";
98
import { Cursor } from "./Cursor";
109
import { computePath, getYForX, type ComputePathProps, computeGraphData } from "./Math";
1110
import {
@@ -24,7 +23,6 @@ export type LineChartProps = ViewProps & {
2423
curveType?: ComputePathProps["curveType"];
2524
/** A worklet function to format a given price. */
2625
formatter?: (price: number) => string;
27-
BannerComponent?: React.FC<BannerComponentProps>;
2826
TopAxisLabel?: React.FC<AxisLabelComponentProps>;
2927
BottomAxisLabel?: React.FC<AxisLabelComponentProps>;
3028
};
@@ -34,7 +32,6 @@ export const LineChart: React.FC<LineChartProps> = ({
3432
strokeWidth = DEFAULT_STROKE_WIDTH,
3533
cursorRadius = DEFAULT_CURSOR_RADIUS,
3634
curveType = DEFAULT_CURVE_TYPE,
37-
BannerComponent = null,
3835
formatter = DEFAULT_FORMATTER,
3936
TopAxisLabel = null,
4037
BottomAxisLabel = null,

0 commit comments

Comments
 (0)