Skip to content

Commit

Permalink
prevent firing change when typing numbers < min
Browse files Browse the repository at this point in the history
  • Loading branch information
SergioCrisostomo committed Oct 27, 2017
1 parent 7d25930 commit a892ba6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/components/input-number/input-number.vue
Expand Up @@ -263,6 +263,7 @@
if (!isNaN(val) && !isEmptyString) {
this.currentValue = val;
if (event.type == 'input' && val < min) return; // prevent fire early in case user is typing a bigger number. Change will handle this otherwise.
if (val > max) {
this.setValue(max);
} else if (val < min) {
Expand Down

0 comments on commit a892ba6

Please sign in to comment.