@types/jquery-maskmoney
TypeScript icon, indicating that this package has built-in type declarations

3.0.4 • Public • Published

Installation

npm install --save @types/jquery-maskmoney

Summary

This package contains type definitions for jquery-maskmoney (https://github.com/plentz/jquery-maskmoney).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jquery-maskmoney.

index.d.ts

/// <reference types="jquery" />

declare namespace jQueryMaskMoney {
    interface Options {
        /**
         * The prefix to be displayed before the value entered
         */
        prefix?: string | undefined;

        /**
         * The prefix to be displayed after the value entered
         */
        suffix?: string | undefined;

        /**
         * Set if the prefix and suffix will stay in the field's value after the user exits the field
         */
        affixesStay?: boolean | undefined;

        /**
         * The thousands separator
         */
        thousands?: string | undefined;

        /**
         * The decimal separator
         */
        decimal?: string | undefined;

        /**
         * How many decimal places are allowed
         */
        precision?: number | undefined;

        /**
         * Setting to prevent users from inputing zero
         */
        allowZero?: boolean | undefined;

        /**
         * Setting to prevent negative values
         */
        allowNegative?: boolean | undefined;
    }
}
interface JQuery {
    /**
     * Apply mask to input, can be pass default value to it
     */
    maskMoney(methodName: "mask", defaultValue?: number): JQuery;

    /**
     * Returns a float value from input field masked
     */
    maskMoney(method?: "unmasked"): number[];

    /**
     * Apply mask to input when the argument are options
     * Remove maskMoney from an element when the argument is "destroy"
     */
    maskMoney(methodOrOption?: "destroy" | jQueryMaskMoney.Options): JQuery;
}

Additional Details

  • Last updated: Tue, 07 Nov 2023 03:09:37 GMT
  • Dependencies: @types/jquery

Credits

These definitions were written by Anderson Friaça.

Readme

Keywords

none

Package Sidebar

Install

npm i @types/jquery-maskmoney

Weekly Downloads

82

Version

3.0.4

License

MIT

Unpacked Size

5.84 kB

Total Files

5

Last publish

Collaborators

  • types