Skip to content

Commit

Permalink
Update CheckboxGroup.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
doom-9-zz authored and doom-9 committed Jul 15, 2021
1 parent 10a12bb commit b43d0d8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/checkbox/src/CheckboxGroup.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,16 +85,16 @@ export default defineComponent({

const minRef = computed(() => {
if (props.min && props.max) {
return Math.min(props.min, props.max)
return Math.floor(Math.min(props.min, props.max))
} else {
return props.min || 0
return props.min ? Math.floor(props.min) : 0
}
})
const maxRef = computed(() => {
if (props.min && props.max) {
return Math.max(props.min, props.max)
return Math.floor(Math.max(props.min, props.max))
} else {
return props.max || Infinity
return props.max ? Math.floor(props.max) : Infinity
}
})

Expand Down

0 comments on commit b43d0d8

Please sign in to comment.