@types/react-signature-canvas
TypeScript icon, indicating that this package has built-in type declarations

1.0.5 • Public • Published

Installation

npm install --save @types/react-signature-canvas

Summary

This package contains type definitions for react-signature-canvas (https://github.com/agilgur5/react-signature-canvas).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-signature-canvas.

index.d.ts

import * as React from "react";
import SignaturePad = require("signature_pad");

export interface ReactSignatureCanvasProps extends SignaturePad.SignaturePadOptions {
    canvasProps?: React.CanvasHTMLAttributes<HTMLCanvasElement> | undefined;
    clearOnResize?: boolean | undefined;
}

declare class ReactSignatureCanvas extends React.Component<ReactSignatureCanvasProps> {
    on: SignaturePad["on"];

    off: SignaturePad["off"];

    clear: SignaturePad["clear"];

    isEmpty: SignaturePad["isEmpty"];

    fromDataURL: SignaturePad["fromDataURL"];

    toDataURL: SignaturePad["toDataURL"];

    fromData: SignaturePad["fromData"];

    toData: SignaturePad["toData"];

    getCanvas(): HTMLCanvasElement;

    getTrimmedCanvas(): HTMLCanvasElement;

    getSignaturePad(): SignaturePad;
}

export default ReactSignatureCanvas;

Additional Details

Credits

These definitions were written by Kamil Socha.

Readme

Keywords

none

Package Sidebar

Install

npm i @types/react-signature-canvas

Weekly Downloads

110,439

Version

1.0.5

License

MIT

Unpacked Size

4.51 kB

Total Files

5

Last publish

Collaborators

  • types