vuetifyjs / vuetify

🐉 Vue Component Framework
https://vuetifyjs.com
MIT License
39.11k stars 6.92k forks source link

fix(VNumberInput): fix behavior with float step #19657

Closed coderkatze closed 3 weeks ago

coderkatze commented 3 weeks ago

Description

This change fixes #19494 by parsing the input value as a float for the model update. It is needed to allow using the VNumberInput with float values and float steps. It also fixes the behavior of the input when blurring / focussing. (the model-value beig set to the parseInt result)

Markup:

<template>
  <v-app>
    <v-container>
      <v-number-input step="0.1" />
    </v-container>
  </v-app>
</template>

<script>
  export default {
    name: 'Playground',
    setup () {
      return {
        //
      }
    },
  }
</script>
yuwu9145 commented 3 weeks ago

Thanks for your PR! The fix has been addressed in another large enhance refactoring PR #19605 aiming to avoid all native number input quirks.