Remove text and add Icon

This commit is contained in:
PascalMarchesseault
2025-01-28 18:37:17 -05:00
parent ff135a8f4f
commit 641e02abc9
2 changed files with 49 additions and 16 deletions

View File

@@ -3,7 +3,18 @@
<div v-if="!isMobile"> <div v-if="!isMobile">
<div class="shadow-lg rounded-2xl mt-2"> <div class="shadow-lg rounded-2xl mt-2">
<div class="relative z-20"> <div class="relative z-20">
<div class="min-h-8 rounded-t-2xl shadow-lg" :style="{ backgroundColor: branding.colors.primary }"></div> <div class="min-h-12 rounded-t-2xl shadow-lg flex justify-end align-center"
:style="{ backgroundColor: branding.colors.primary, color: branding.colors.onPrimary }">
<v-btn v-if="isCreatorConnected"
variant="text"
class="mx-5"
:to="'/profile'">
<v-icon size="32">mdi-palette</v-icon>
</v-btn>
</div>
<!-- Banner --> <!-- Banner -->
<div class="relative"> <div class="relative">
<div> <div>
@@ -20,22 +31,32 @@
</div> </div>
</div> </div>
<!-- Mobile --> <!-- Mobile -->
<div v-if="isMobile"> <div v-if="isMobile">
<div class="shadow-lg rounded-2xl "> <div class="shadow-lg rounded-2xl">
<div class="relative z-20"> <div class="relative z-20">
<div class="shadow-2xl flex items-center px-2 py-2" <div class="shadow-2xl flex items-center px-2 py-2"
:style="{ backgroundColor: branding.colors.primary, color: branding.colors.onPrimary }"> :style="{ backgroundColor: branding.colors.primary, color: branding.colors.onPrimary }">
<router-link to="/@Hutopy"> <router-link to="/@Hutopy">
<div class="flex items-center"> <div class="flex items-center">
<HutopySvg></HutopySvg> <HutopySvg></HutopySvg>
<div class="text-xl font-bold -ml-2 ">Hutopy</div> <div class="text-xl font-bold -ml-2">Hutopy</div>
</div> </div>
</router-link> </router-link>
<div class="flex-1"></div> <div class="flex-1"></div>
<v-btn v-if="isCreatorConnected"
variant="text"
class="mr-4"
:to="'/profile'"
>
<v-icon size="32">mdi-palette</v-icon>
</v-btn>
<router-link to="/login"> <router-link to="/login">
<button class="lg:hidden flex items-center justify-center mr-4"> <button class="lg:hidden flex items-center justify-center mr-4">
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
@@ -51,7 +72,7 @@
<div> <div>
<img <img
class="w-full drop-shadow-[0_10px_6px_rgba(0,0,0,0.25)]" class="w-full drop-shadow-[0_10px_6px_rgba(0,0,0,0.25)]"
:src="branding.value.images.banner ? branding.value.images.banner : '/images/placeholders/banner.png'" :src="branding.value.images.banner || '/images/placeholders/banner.png'"
alt="Profile Banner" alt="Profile Banner"
style="max-height: 425px" style="max-height: 425px"
> >
@@ -65,13 +86,17 @@
<script setup> <script setup>
import {ref, onMounted, onBeforeUnmount} from "vue"; import {ref, onMounted, onBeforeUnmount, computed} from "vue";
import BannerActions from "@/views/creators/BannerActions.vue"; import BannerActions from "@/views/creators/BannerActions.vue";
import {useBrandingStore} from "@/stores/brandingStore.js";
import HutopySvg from "@/views/svg/HutopySvg.vue"; import HutopySvg from "@/views/svg/HutopySvg.vue";
import {useBrandingStore} from "@/stores/brandingStore.js";
import {useCreatorProfileStore} from "@/stores/creatorProfileStore.js";
const branding = useBrandingStore(); const branding = useBrandingStore();
const creatorProfileStore = useCreatorProfileStore();
const isMobile = ref(false); const isMobile = ref(false);
function updateIsMobile() { function updateIsMobile() {
@@ -81,14 +106,26 @@ function updateIsMobile() {
onMounted(() => { onMounted(() => {
updateIsMobile(); updateIsMobile();
window.addEventListener("resize", updateIsMobile); window.addEventListener("resize", updateIsMobile);
if (!creatorProfileStore.creator) {
creatorProfileStore.fetchCreatorData?.();
}
}); });
onBeforeUnmount(() => { onBeforeUnmount(() => {
window.removeEventListener("resize", updateIsMobile); window.removeEventListener("resize", updateIsMobile);
}); });
// Vérification si le créateur est connecté
const isCreatorConnected = computed(() => {
const creatorId = creatorProfileStore.creator?.id || null;
const brandingId = branding.value?.id || null;
return creatorId && brandingId && creatorId === brandingId;
});
</script> </script>
<style> <style>
</style> </style>

View File

@@ -115,10 +115,6 @@ import Footer from "@/views/main/Footer.vue";
</template> </template>
<style scoped> <style scoped>
.bg-primary{
background-color: #6A0164;
}
.box-text{ .box-text{
color: #6A0164; color: #6A0164;
font-size: 30px; font-size: 30px;
@@ -185,7 +181,7 @@ body {
} }
.support-text { .support-text {
font-size: 2.5rem; /* Ajustez la taille du texte */ font-size: 2.2rem; /* Ajustez la taille du texte */
line-height: 1.1; /* Ajustez l'espacement entre les lignes */ line-height: 1.1; /* Ajustez l'espacement entre les lignes */
text-align: left; /* Alignement du texte à gauche */ text-align: left; /* Alignement du texte à gauche */
font-weight: bold; /* Rend le texte gras */ font-weight: bold; /* Rend le texte gras */