Skip to content

Commit 9317296

Browse files
committed
refactor: remove redundant type definition
1 parent 021db0d commit 9317296

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

resources/js/pages/auth/TwoFactorChallenge.vue

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { Input } from '@/components/ui/input';
55
import { PinInput, PinInputGroup, PinInputSlot } from '@/components/ui/pin-input';
66
import AuthLayout from '@/layouts/AuthLayout.vue';
77
import { Form, Head } from '@inertiajs/vue3';
8-
import { computed, ComputedRef, ref } from 'vue';
8+
import { computed, ref } from 'vue';
99
1010
interface AuthConfigContent {
1111
title: string;
@@ -38,7 +38,7 @@ const toggleRecoveryMode = (clearErrors: () => void): void => {
3838
};
3939
4040
const code = ref<number[]>([]);
41-
const codeValue: ComputedRef<string> = computed(() => code.value.join(''));
41+
const codeValue = computed((): string => code.value.join(''));
4242
</script>
4343

4444
<template>
@@ -52,7 +52,7 @@ const codeValue: ComputedRef<string> = computed(() => code.value.join(''));
5252
method="post"
5353
class="space-y-4"
5454
reset-on-error
55-
@error="code=[]"
55+
@error="code = []"
5656
#default="{ errors, processing, clearErrors }"
5757
>
5858
<input type="hidden" name="code" :value="codeValue" />
@@ -81,7 +81,13 @@ const codeValue: ComputedRef<string> = computed(() => code.value.join(''));
8181
</template>
8282

8383
<template v-else>
84-
<Form :action="route('two-factor.login')" method="post" class="space-y-4" reset-on-error #default="{ errors, processing, clearErrors }">
84+
<Form
85+
:action="route('two-factor.login')"
86+
method="post"
87+
class="space-y-4"
88+
reset-on-error
89+
#default="{ errors, processing, clearErrors }"
90+
>
8591
<Input name="recovery_code" type="text" placeholder="Enter recovery code" :autofocus="showRecoveryInput" required />
8692
<InputError :message="errors.recovery_code" />
8793
<Button type="submit" class="w-full" :disabled="processing">Continue</Button>

0 commit comments

Comments
 (0)