25 lines
531 B
Vue
25 lines
531 B
Vue
<script setup lang="ts">
|
|
import { useMailStore } from '~/stores/mail'
|
|
|
|
const store = useMailStore()
|
|
const { syncing } = storeToRefs(store)
|
|
|
|
const { t } = useI18n()
|
|
|
|
async function handleRefresh(): Promise<void> {
|
|
await store.triggerSync()
|
|
}
|
|
</script>
|
|
|
|
<template>
|
|
<MalioButton
|
|
:label="t('mail.actions.refresh')"
|
|
variant="secondary"
|
|
icon-name="material-symbols:refresh"
|
|
icon-position="left"
|
|
:icon-size="16"
|
|
:disabled="syncing"
|
|
@click="handleRefresh"
|
|
/>
|
|
</template>
|