react-textarea-autocomplete: Allow all textarea attributes (#43492)

This commit is contained in:
Aarni Koskela 2020-04-01 00:26:22 +03:00 committed by GitHub
parent 2bcc698e2d
commit 5d691af616
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 4 deletions

View File

@ -1,4 +1,4 @@
// Type definitions for webscopeio__react-textarea-autocomplete 2.3
// Type definitions for webscopeio__react-textarea-autocomplete 4.6
// Project: https://github.com/webscopeio/react-textarea-autocomplete
// Definitions by: Michal Zochowski <https://github.com/michauzo>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
@ -68,9 +68,7 @@ export interface TriggerType<TItem> {
[key: string]: SettingType<TItem>;
}
type PickedAttributes = "onChange" | "onSelect" | "onBlur" | "value";
export interface TextareaProps<TItem> extends Pick<React.InputHTMLAttributes<HTMLTextAreaElement>, PickedAttributes> {
export interface TextareaProps<TItem> extends React.TextareaHTMLAttributes<HTMLTextAreaElement> {
/**
* Define triggers and their corresponding behavior.
*/

View File

@ -22,6 +22,7 @@ class Autocomplete extends React.Component {
render() {
return <ReactTextareaAutocomplete<string>
rows={8}
className="my-textarea"
loadingComponent={Loading}
style={{