npm.io
0.5.6 • Published 2 years ago

@types/react-notify-toast

Licence
MIT
Version
0.5.6
Deps
1
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/react-notify-toast

Summary

This package contains type definitions for react-notify-toast (https://github.com/jesusoterogomez/react-notify-toast).

Details

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

index.d.ts

import * as React from "react";

interface reactNotifyToastColor {
    background: string;
    text: string;
}

declare class reactNotifyToast {
    show(
        text: string,
        type?: "success" | "error" | "warning" | "custom",
        timeout?: number,
        color?: reactNotifyToastColor,
    ): void;

    hide(): void;
    createShowQueue(): reactNotifyToast;
}

interface Options {
    wrapperId?: string | undefined;
    animationDuration?: number | undefined;
    timeout?: number | undefined;
    zIndex?: number | undefined;
    top?: number | string | undefined;
    colors?: any;
}

interface NotificationProps {
    options?: Options | undefined;
}

export class Notification extends React.Component<NotificationProps, any> {}

export const notify: reactNotifyToast;
export default Notification;

Additional Details

  • Last updated: Tue, 07 Nov 2023 0939 GMT
  • Dependencies: @types/react

Credits

These definitions were written by Klaas Cuvelier.