Blockbench Reference Docs
    Preparing search index...
    interface DragHandler {
        cb: (files: FileResult[], event: DragEvent) => void;
        condition?: any;
        delete: () => void;
        element?: string | HTMLElement | (() => string | boolean | HTMLElement);
        errorbox?: boolean;
        extensions: string[] | (() => string[]);
        propagate?: boolean;
        readtype?: ReadType;
    }

    Hierarchy (View Summary)

    Index

    Properties

    cb: (files: FileResult[], event: DragEvent) => void
    condition?: any

    Whether or not to enable the drag handler

    delete: () => void
    element?: string | HTMLElement | (() => string | boolean | HTMLElement)

    Drop target element

    errorbox?: boolean

    Whether to display an error box when importing a dragged file fails

    extensions: string[] | (() => string[])

    Allowed file extensions

    propagate?: boolean

    If true, the drop will work on all child elements of the specified element

    readtype?: ReadType