- Notifications
You must be signed in to change notification settings - Fork 118
Closed
Description
Hi,
Expected Behavior
If v-model value is 0.00 then input field should clear on focus
Actual Behavior
Input remains same
Steps to Reproduce the Problem
http://jsfiddle.net/cvg6c4r3/6/
I have also tried adding a directive but no luck
Vue.directive('clear-zero', { bind: function (el, binding, vnode) { el.onfocus = function () { if (parseFloat(el.value) === 0) { console.log('Clear value'); el.value = null; } }; } });<vue-numeric v-clear-zero currency="$" :precision="2" v-model.number="money"></vue-numeric>Specifications
- Plugin Version: 2.2.3+
- Vue.js Version: 2.5.2/2.4.4
- Browser: chrome 62 beta
- OS: macOs sierra
Ref #26
Metadata
Metadata
Assignees
Labels
No labels