feat: add current-device logout
This commit is contained in:
+10
-1
@@ -455,6 +455,15 @@ async function bootstrap() {
|
||||
authReady.value = true
|
||||
}
|
||||
}
|
||||
function completeLogout() {
|
||||
authenticated.value = false
|
||||
password.value = ''
|
||||
error.value = ''
|
||||
mobileSidebar.value = false
|
||||
mobileDetail.value = false
|
||||
selectedTask.value = null
|
||||
}
|
||||
|
||||
async function submitAuth() {
|
||||
error.value = ''
|
||||
try {
|
||||
@@ -1588,7 +1597,7 @@ onUnmounted(() => {
|
||||
<div v-if="!['today','tasks','upcoming','habits','settings'].includes(activeView)" class="topbar-title"><h1 :title="activeName">{{ activeName }}</h1></div>
|
||||
</header>
|
||||
<template v-if="['habits','settings'].includes(activeView)">
|
||||
<MvpPanel ref="habitComposer" :key="activeView" :view="activeView as 'habits'|'settings'" :show-completed="showCompleted" @update:show-completed="showCompleted=$event" @changed="refreshAll" @notice="toast" />
|
||||
<MvpPanel ref="habitComposer" :key="activeView" :view="activeView as 'habits'|'settings'" :show-completed="showCompleted" @update:show-completed="showCompleted=$event" @changed="refreshAll" @notice="toast" @logout="completeLogout" />
|
||||
</template>
|
||||
<MemoPanel v-else-if="activeView==='memos'" ref="memoPanel" :request="api" @scope="memoTrash=$event==='trash'" @detail="memoDetailOpen=$event" @notice="toast" />
|
||||
<CountdownPanel ref="countdownComposer" v-else-if="activeView==='countdowns'" @notice="toast" />
|
||||
|
||||
Reference in New Issue
Block a user