Skip to content

Commit

Permalink
fixed typings to work properly
Browse files Browse the repository at this point in the history
  • Loading branch information
bovan committed Nov 10, 2020
1 parent 70f97ae commit 8df6ad5
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions types/react-datasheet.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -147,17 +147,17 @@ declare namespace ReactDataSheet {
export type ContextMenuHandler<T extends Cell<T, V>, V = string> = (event: MouseEvent, cell: T, row : number, col: number) => void;

/* Props available for handleCopy */
export type HandleCopyProps<T, V> = {
event: Event,
dataRenderer: DataRenderer<T, V>,
valueRenderer: ValueRenderer<T, V>,
data: T[][],
start: Location,
end: Location,
range: (start: number, end: number) => []
export interface HandleCopyProps<T extends Cell<T, V>, V = string> {
event: Event;
dataRenderer: DataRenderer<T, V>;
valueRenderer: ValueRenderer<T, V>;
data: T[][];
start: Location;
end: Location;
range: (start: number, end: number) => [];
}

export type HandleCopyFunction<T, V> = (obj: HandleCopyProps<T, V>) => void;
export type HandleCopyFunction<T extends Cell<T, V>, V = string> = (props: HandleCopyProps<T, V>) => void;

/** The properties that will be passed to the CellRenderer component or function. */
export interface CellRendererProps<T extends Cell<T, V>, V = string> {
Expand Down

0 comments on commit 8df6ad5

Please sign in to comment.