Properly implement preventDefault

This commit is contained in:
Matthias 2022-12-13 20:25:46 +01:00
parent 40d0691fd3
commit 4da60605e0

View File

@ -8,7 +8,6 @@
v-model="loginViewOpen"
title="Login to your bot"
@ok="handleOk"
@hide.prevent
>
<login ref="loginForm" in-modal :existing-auth="loginInfo" @loginResult="handleLoginResult" />
</b-modal>
@ -32,7 +31,8 @@ const handleLoginResult = (result: boolean) => {
loginViewOpen.value = false;
}
};
const handleOk = () => {
const handleOk = (evt) => {
evt.preventDefault();
loginForm.value?.handleSubmit();
};
const openLoginModal = async (botInfo: AuthStorageWithBotId | undefined = undefined) => {