Money
Money Vue input component
Can be used outside of the Enso ecosystem.
For live examples and demos, you may visit laravel-enso.com
Installation
Install the package:
yarn add @enso-ui/money
(within Enso, remember to cd
into the client
folder before installing front-end assets)
Exports
@enso-ui/money
:
Money
Usage
Import the desired component(s):
import Money from '@enso-ui/money';
Money
The bulma styled money input component.
Example:
<money v-model="myModel"
symbol="$"
decimal=","/>
Props
label
-boolean
, optional, - if true, the value is shown as a label instead of an inputreadonly
-boolean
, optional - if true, the component is readonlydisabled
-boolean
, optional - if true, the component is disabledplaceholder
-string
, optional - the money input placeholdersymbol
-string
, optional, default$
- the currency symboldecimal
-string
, optional, default.
- the decimal separator. Valid values are '.', ','thousand
-string
, optional, default,
, the thousand separator. Valid values are ' ', '.', ','precision
-number
, optional, default2
- the precisionpositive
-string
, optional, default%s %v
- the template for positive values (symbol, value)negative
-string
, optional, default%s (%v)
, the template for negative values (symbol, value)zero
-string
, optional, default%s --
,the template for zero (symbol, value)
Events:
input
, on the money input blur
Methods
format
, formats the value based on the given options and emits an 'input' event
Questions & Issues
For questions and support please use the issues functionality for this package's github repository.
Please make sure to search for existing issues before creating a new issue, and when opening a new issue, fill the required information in the issue template.
Issues not conforming to the guidelines may be closed immediately.
External Dependencies
Money uses accounting.js for formatting numbers
Contributions
are welcome. Pull requests are great, but issues are good too.
Thank you to all the people who already contributed to Enso!
License
← Modal Permissions →