|
|
@ -3,10 +3,13 @@ import MdiAt from '~icons/mdi/at' |
|
|
|
import MdiLogout from '~icons/mdi/logout' |
|
|
|
import MdiLogout from '~icons/mdi/logout' |
|
|
|
import MdiDotsVertical from '~icons/mdi/dots-vertical' |
|
|
|
import MdiDotsVertical from '~icons/mdi/dots-vertical' |
|
|
|
import MaterialSymbolsMenu from '~icons/material-symbols/menu' |
|
|
|
import MaterialSymbolsMenu from '~icons/material-symbols/menu' |
|
|
|
|
|
|
|
import MdiReload from '~icons/mdi/reload' |
|
|
|
import { navigateTo } from '#app' |
|
|
|
import { navigateTo } from '#app' |
|
|
|
|
|
|
|
|
|
|
|
const { $state } = useNuxtApp() |
|
|
|
const { $state } = useNuxtApp() |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const { isLoading } = useApi() |
|
|
|
|
|
|
|
|
|
|
|
const sidebar = ref<HTMLDivElement>() |
|
|
|
const sidebar = ref<HTMLDivElement>() |
|
|
|
|
|
|
|
|
|
|
|
const email = computed(() => $state.user?.value?.email ?? '---') |
|
|
|
const email = computed(() => $state.user?.value?.email ?? '---') |
|
|
@ -16,11 +19,9 @@ const signOut = () => { |
|
|
|
navigateTo('/signin') |
|
|
|
navigateTo('/signin') |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const toggleSidebar = useToggle($state.sidebarOpen) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const sidebarOpen = computed({ |
|
|
|
const sidebarOpen = computed({ |
|
|
|
get: () => !$state.sidebarOpen.value, |
|
|
|
get: () => !$state.sidebarOpen.value, |
|
|
|
set: (val) => toggleSidebar(val), |
|
|
|
set: (val) => ($state.sidebarOpen.value = !val), |
|
|
|
}) |
|
|
|
}) |
|
|
|
</script> |
|
|
|
</script> |
|
|
|
|
|
|
|
|
|
|
@ -41,15 +42,9 @@ const sidebarOpen = computed({ |
|
|
|
<span class="prose-xl">NocoDB</span> |
|
|
|
<span class="prose-xl">NocoDB</span> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<!-- todo: loading is not yet supported by nuxt 3 - see https://v3.nuxtjs.org/migration/component-options#loading |
|
|
|
<div v-show="isLoading" class="text-gray-400 ml-3"> |
|
|
|
<span v-show="$nuxt.$loading.show" class="caption grey--text ml-3"> |
|
|
|
{{ $t('general.loading') }} <MdiReload :class="{ 'animate-infinite animate-spin !text-success': isLoading }" /> |
|
|
|
{{ $t('general.loading') }} <v-icon small color="grey">mdi-spin mdi-loading</v-icon> |
|
|
|
</div> |
|
|
|
</span> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
todo: replace shortkey? |
|
|
|
|
|
|
|
<span v-shortkey="['ctrl', 'shift', 'd']" @shortkey="openDiscord" /> |
|
|
|
|
|
|
|
--> |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<div class="flex-1" /> |
|
|
|
<div class="flex-1" /> |
|
|
|