setup wizard funcionality upgrade for v2

This commit is contained in:
Čarodej
2022-02-11 10:05:12 +01:00
parent 3867c9cd67
commit 03730b80c0
33 changed files with 517 additions and 448 deletions
@@ -1,5 +1,5 @@
<template>
<div class="flex h-full items-center justify-center" v-if="isLoading || isEmpty">
<div class="flex h-screen items-center justify-center" v-if="isLoading || isEmpty">
<!--Show message for user-->
<div v-if="!isLoading" class="text-content text-center">
<slot></slot>
@@ -39,7 +39,7 @@ export default {
},
},
created() {
this.isVisibleDisclaimer = !localStorage.getItem('isHiddenDisclaimer')
this.isVisibleDisclaimer = this.config.installation === 'installation-done' && !localStorage.getItem('isHiddenDisclaimer')
},
}
</script>
@@ -25,10 +25,10 @@
<image-icon size="34" class="vue-feather text-theme inline-block mb-4" />
<b class="font-bold text-base block leading-3">
{{ $t('input_image.title') }}
{{ $te('input_image.title') || 'Upload Image' }}
</b>
<small class="text-xs text-gray-500">
{{ $t('input_image.supported') }}
{{ $te('input_image.supported') || 'Supported formats are .png, .jpg, .jpeg.' }}
</small>
</div>
</div>
@@ -91,7 +91,7 @@ export default {
openMenu() {
this.isOpen = !this.isOpen
if (this.isOpen) {
if (this.$refs.search && this.isOpen) {
this.$nextTick(() => this.$refs.search.focus())
}
},
@@ -4,7 +4,7 @@
<UserHeadline v-if="!clickedSubmenu" class="p-5 pb-3" />
<!--User estimate-->
<div v-if="config.subscriptionType === 'metered' && user && !clickedSubmenu" class="block px-5 pt-2">
<div v-if="config.subscriptionType === 'metered' && user && user.data.meta.usages && !clickedSubmenu" class="block px-5 pt-2">
<div class="rounded-lg bg-light-background px-3 py-1.5 dark:bg-4x-dark-foreground">
<span class="text-sm font-semibold">
{{ $t('Your current estimated usage:') }}
@@ -5,7 +5,7 @@
<MemberAvatar class="mx-auto inline-block" :size="44" :is-border="false" :member="user" />
<!--Usage-->
<div v-if="config.subscriptionType === 'metered'" class="mt-1 text-center leading-3">
<div v-if="config.subscriptionType === 'metered' && user.data.meta.usages" class="mt-1 text-center leading-3">
<b class="text-theme block text-xs font-bold leading-3">
{{ user.data.meta.usages.costEstimate }}
</b>