Skip to content

Commit d2ef881

Browse files
authored
chore: organize
1 parent 2c3c823 commit d2ef881

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

packages/bootstrap-vue-3/src/components/BFormInput/BFormInput.vue

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<input
33
:id="computedId"
44
ref="input"
5-
:class="classes"
5+
:class="computedClasses"
66
:name="name || undefined"
77
:form="form || undefined"
88
:type="localType"
@@ -59,9 +59,11 @@ export default defineComponent({
5959
},
6060
emits: ['update:modelValue', 'change', 'blur', 'input'],
6161
setup(props, {emit}) {
62+
const {input, computedId, computedAriaInvalid, onInput, onChange, onBlur, focus, blur} = useFormInput(props, emit)
63+
6264
const isHighlighted = ref(false)
6365
64-
const classes = computed(() => {
66+
const computedClasses = computed(() => {
6567
const isRange = props.type === 'range'
6668
const isColor = props.type === 'color'
6769
return {
@@ -80,9 +82,6 @@ export default defineComponent({
8082
allowedTypes.includes(props.type) ? props.type : 'text'
8183
)
8284
83-
const {input, computedId, computedAriaInvalid, onInput, onChange, onBlur, focus, blur} =
84-
useFormInput(props, emit)
85-
8685
const highlight = () => {
8786
if (isHighlighted.value === true) return
8887
isHighlighted.value = true
@@ -92,7 +91,7 @@ export default defineComponent({
9291
}
9392
9493
return {
95-
classes,
94+
computedClasses,
9695
localType,
9796
input,
9897
computedId,

0 commit comments

Comments
 (0)