From 5f5aded277baca8df445bf258a80b3b580ff7f42 Mon Sep 17 00:00:00 2001 From: Zach Posten Date: Fri, 4 Jan 2019 13:24:00 -0600 Subject: [PATCH] feat: Add the remainder of the FilePond object methods See: https://pqina.nl/filepond/docs/patterns/api/filepond-object/ --- types/react-filepond/index.d.ts | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/types/react-filepond/index.d.ts b/types/react-filepond/index.d.ts index 360eefefc8..201c72fbc5 100644 --- a/types/react-filepond/index.d.ts +++ b/types/react-filepond/index.d.ts @@ -232,4 +232,22 @@ export class FilePond extends React.Component { context: () => void; } +/** Creates a new FilePond instance */ +export function create(element?: any, options?: FilePondProps): void; +/** Destroys the FilePond instance attached to the supplied element */ +export function destroy(element: any): void; +/** Returns the FilePond instance attached to the supplied element */ +export function find(element: any): FilePond; +/** + * Parses a given section of the DOM tree for elements with class + * .filepond and turns them into FilePond elements. + */ +export function parse(context: any): void; +/** Registers a FilePond plugin for later use */ export function registerPlugin(...plugins: any[]): void; +/** Sets page level default options for all FilePond instances */ +export function setOptions(options: FilePondProps): void; +/** Returns the current default options */ +export function getOptions(): FilePondProps; +/** Determines whether or not the browser supports FilePond */ +export function supported(): boolean;