Skip to content

Commit

Permalink
fix(header): i18n and position in logged icon
Browse files Browse the repository at this point in the history
  • Loading branch information
Novout committed Apr 24, 2023
1 parent c9b8eff commit 3085b11
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<Menu as="div" class="relative">
<MenuButton class="rounded-full w-8"><UseImage
<MenuButton class="flex justify-center items-center rounded-full w-8"><UseImage
:src="user?.user_metadata.avatar_url"
>
<template #loading>
Expand Down Expand Up @@ -46,13 +46,13 @@ v-motion
<MenuItem @click="plugin.emit('plugin-oauth-logout')">
<button class="flex wb-icon rounded shadow px-2 justify-between items-center bg-theme-background-1">
<IconLogout class="w-7 h-7" />
<p class="font-bold">Logout</p>
<p class="font-bold">{{ t('editor.header.login.logout') }}</p>
</button>
</MenuItem>
<MenuItem @click="plugin.emit('plugin-oauth-delete')">
<button class="flex wb-icon rounded shadow px-2 justify-between items-center bg-theme-background-1">
<IconDelete class="w-7 h-7" />
<p class="font-bold">Delete</p>
<p class="font-bold">{{ t('editor.header.login.delete') }}</p>
</button>
</MenuItem>
</MenuItems>
Expand All @@ -64,8 +64,10 @@ v-motion
import { UseImage } from '@vueuse/components'
import { usePlugin } from 'better-write-plugin-core'
import { computed } from 'vue'
import { useI18n } from 'vue-i18n'
const plugin = usePlugin()
const { t } = useI18n()
const AUTH = useAuthStore()
const user = computed(() => AUTH.account.user)
Expand Down
4 changes: 4 additions & 0 deletions packages/languages/src/en-US/editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ export default {
tools: 'Tools',
vault: 'Void',
help: 'Help',
login: {
logout: 'Logout',
delete: 'Delete',
},
},
auth: {
login: {
Expand Down
4 changes: 4 additions & 0 deletions packages/languages/src/pt-BR/editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ export default {
tools: 'Ferramentas',
vault: 'Vazio',
help: 'Ajuda',
login: {
logout: 'Sair',
delete: 'Deletar',
},
},
auth: {
login: {
Expand Down

0 comments on commit 3085b11

Please sign in to comment.