Skip to content

Commit a07ed95

Browse files
fix(content-uploader): update handleChange to onChange in Flow types
Co-Authored-By: gregorywong@box.com <gregorywong@box.com>
1 parent 11a4452 commit a07ed95

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/elements/content-uploader/UploadInput.js.flow

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
import * as React from 'react';
99

1010
type Props = {
11-
handleChange: Function,
11+
onChange: Function,
1212
/** Optional callback to validate files before selection. Return false to prevent selection. */
1313
onSelection?: (files: FileList) => boolean,
1414
inputLabel?: React.Node,
@@ -18,11 +18,12 @@ type Props = {
1818
};
1919

2020
const UploadInput = ({
21-
handleChange,
21+
onChange,
2222
inputLabel,
2323
inputLabelClass = '',
2424
isFolderUpload = false,
2525
isMultiple = true,
26+
onSelection,
2627
}: Props) => {
2728
const inputRef = React.useRef(null);
2829

@@ -49,7 +50,7 @@ const UploadInput = ({
4950
return;
5051
}
5152
}
52-
handleChange(event);
53+
onChange(event);
5354
}}
5455
ref={inputRef}
5556
type="file"

0 commit comments

Comments
 (0)