fix #52
This commit is contained in:
parent
b5c328b91b
commit
c8f99347d2
4 changed files with 18 additions and 3 deletions
|
|
@ -42,6 +42,7 @@
|
||||||
<router-link
|
<router-link
|
||||||
:to="mainItem.path"
|
:to="mainItem.path"
|
||||||
:aria-current="isCurrent(mainItem)"
|
:aria-current="isCurrent(mainItem)"
|
||||||
|
@click="collapse()"
|
||||||
>{{ mainItem.title }}</router-link
|
>{{ mainItem.title }}</router-link
|
||||||
>
|
>
|
||||||
<span
|
<span
|
||||||
|
|
@ -61,6 +62,7 @@
|
||||||
<router-link
|
<router-link
|
||||||
:to="project.uri"
|
:to="project.uri"
|
||||||
:class="hasUnreadNotification(project) ? 'new' : undefined"
|
:class="hasUnreadNotification(project) ? 'new' : undefined"
|
||||||
|
@click="collapse()"
|
||||||
>{{ project.title }}</router-link
|
>{{ project.title }}</router-link
|
||||||
>
|
>
|
||||||
</li>
|
</li>
|
||||||
|
|
@ -73,7 +75,9 @@
|
||||||
v-for="project in archivedProjects"
|
v-for="project in archivedProjects"
|
||||||
:class="{ active: isCurrent(project) }"
|
:class="{ active: isCurrent(project) }"
|
||||||
>
|
>
|
||||||
<router-link :to="project.uri">{{ project.title }}</router-link>
|
<router-link :to="project.uri" @click="collapse()">{{
|
||||||
|
project.title
|
||||||
|
}}</router-link>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</details>
|
</details>
|
||||||
|
|
@ -81,10 +85,10 @@
|
||||||
<footer class="w-full">
|
<footer class="w-full">
|
||||||
<ul class="flex">
|
<ul class="flex">
|
||||||
<li data-icon="user" v-if="user?.role !== 'client'">
|
<li data-icon="user" v-if="user?.role !== 'client'">
|
||||||
<router-link to="/profil">Profil</router-link>
|
<router-link to="/profil" @click="collapse()">Profil</router-link>
|
||||||
</li>
|
</li>
|
||||||
<li data-icon="logout">
|
<li data-icon="logout">
|
||||||
<a href="/logout">Déconnexion</a>
|
<a href="/logout" @click="collapse()">Déconnexion</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</footer>
|
</footer>
|
||||||
|
|
@ -145,6 +149,12 @@ function isCurrent(navItem) {
|
||||||
function hasUnreadNotification(project) {
|
function hasUnreadNotification(project) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function collapse() {
|
||||||
|
if (window.innerWidth < 1024) {
|
||||||
|
isExpanded.value = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
|
|
||||||
|
|
@ -62,5 +62,10 @@ export const useAddImagesModalStore = defineStore("add-images-modal", () => {
|
||||||
images.value = tabs.value[2].images = json.page.images;
|
images.value = tabs.value[2].images = json.page.images;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
api.fetchData("inspirations").then((json) => {
|
||||||
|
console.log(json);
|
||||||
|
images.value = tabs.value[3].images = json.page.images;
|
||||||
|
});
|
||||||
|
|
||||||
return { images, activeTabId, tabs, activeTab };
|
return { images, activeTabId, tabs, activeTab };
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue