Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add types: VictorySelectionContainer #1530

Merged
merged 3 commits into from
Apr 29, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Explicitly define funcs
  • Loading branch information
kale-stew committed Apr 29, 2020
commit cdc031555bcebe1d3f04691a1824f52ba56354e5
14 changes: 12 additions & 2 deletions packages/victory-selection-container/src/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
import * as React from "react";
import { VictoryContainerProps } from "victory-core";

interface PointsInterface {
childName?: string | string[];
eventKey?: string | number;
data?: any;
}

interface VictorySelectionContainerProps extends VictoryContainerProps {
activateSelectedData?: boolean;
allowSelection?: boolean;
disable?: boolean;
onSelection?: Function;
onSelectionCleared?: Function;
onSelection?: (
points: PointsInterface[],
bounds: { x: number | Date; y: number | Date }[],
props: VictorySelectionContainerProps
) => void;
onSelectionCleared?: (props: VictorySelectionContainerProps) => void;
selectionBlacklist?: string[];
selectionComponent?: React.ReactElement;
selectionDimension?: "x" | "y";
Expand Down