# vuenos-input-money

> Package for component input money type

Latest version **1.0.5** (published 2022-07-06) · 0 weekly downloads

## Install

```sh
npm install vuenos-input-money
pnpm add vuenos-input-money
yarn add vuenos-input-money
bun add vuenos-input-money
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.5 |
| Published | 2022-07-06 |
| First published | 2022-06-22 |
| Weekly downloads | 0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=12 |
| Dependencies | 2 |
| Unpacked size | 37.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Sơn Nguyễn |
| Maintainers | biennui1998mu |
| Keywords | vue, vue3, vuenos-input-money, input money |

## Links

- npm: https://www.npmjs.com/package/vuenos-input-money
- Repository: https://github.com/biennui1998mu/vuenos-input-money
- Homepage: https://github.com/biennui1998mu/vuenos-input-money#readme
- Issues: https://github.com/biennui1998mu/vuenos-input-money/issues
- npm.io page: https://npm.io/package/vuenos-input-money

## Dependencies (2)

- [sass](https://npm.io/package/sass.md) 1.32.1
- [sass-loader](https://npm.io/package/sass-loader.md) 8.0.2

## Recent versions

- 1.0.5 (latest) — 2022-07-06
- 1.0.4 — 2022-06-24
- 1.0.3 — 2022-06-22
- 1.0.2 — 2022-06-22
- 1.0.1 — 2022-06-22
- 1.0.0 — 2022-06-22
- 0.1.2 — 2022-06-22
- 0.1.1 — 2022-06-22
- 0.1.0 — 2022-06-22

## README

# vuenos-input-money

> description

## Prerequisites

This project using NodeJS (version 16.10.0 or later) and NPM.
[Node](http://nodejs.org/) and [NPM](https://npmjs.org/) are really easy to install.
To make sure you have them available on your machine,
try running the following command.

```sh
$ npm -v && node -v
7.24.0
v16.10.0
```

## Table of contents

- [vuenos-input-money](#vuenos-input-money)
  - [Prerequisites](#prerequisites)
  - [Table of contents](#table-of-contents)
  - [Getting Started](#getting-started)
  - [Installation](#installation)
  - [Usage](#usage)
    - [Import component](#import-component)
    - [Get value input](#get-value-input)
    - [Set value input](#set-value-input)
    - [Trigger blur action](#trigger-blur-action)
  - [Variables binding](#variables-binding)
  - [Versioning](#versioning)
  - [Author](#author)

## Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

## Installation
To install and set up the library, run:
```sh
npm install vuenos-input-money
```

## Usage

### Import component

```html

<VuenosInputMoney ref="InputMoneyRef"
                  @getValue="getMoneyVal"
                  @blur="blurInput"
                  :placeholder="'Số tiền'"
                  :suffix="'VNĐ'"
                  :maxLength="14"
                  :disabled="true"
                  :error="true"
                  :showText="true">
</VuenosInputMoney>
```

```typescript
import VuenosInputMoney from "vuenos-input-money";
```

### Get value input

```typescript
const getMoneyVal = (val) => {
    console.log(val);
}
```

### Set value input

```typescript
const InputMoneyRef = ref<null | { setInput: (val) => null }>(null)
const setInputMoneyVal = (val) => {
    InputMoneyRef.value?.setInput(val)
}
return {
    InputMoneyRef
}
```

### Trigger blur action

```typescript
const blurInput = async () => {
    //do something
}
```

### Variables binding

| ATTRIBUTE   | DESCRIPTION                 | REQUIRED |  TYPE   | ACCEPTED VALUES | DEFAULT |
|:------------|:----------------------------|:--------:|:-------:|----------------:|--------:|
| placeholder | placeholder of input        |          | String  |       'Số tiền' |   empty |
| suffix      | suffix of input             |          | String  |           'VNĐ' |   empty |
| maxLength   | maxlength of input          |          | Number  |              14 |   empty |
| showText    | show convert number to text |          | Boolean |      true/false |   false |
| disabled    | disable input               |          | Boolean |      true/false |   false |
| error       | error style input           |          | Boolean |      true/false |   empty |


## Versioning

v1.0.3

## Author

* **Sơn Nguyễn** - *Initial work* - [Sơn Nguyễn](https://github.com/biennui1998mu)

---
_Source: https://npm.io/package/vuenos-input-money · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
