From a2e7b235fea9123f110408e5d42a257a6d29ce1c Mon Sep 17 00:00:00 2001 From: Franzz Date: Wed, 13 May 2026 23:55:26 +0200 Subject: [PATCH] Force projet if on blog mode --- src/components/project.vue | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/components/project.vue b/src/components/project.vue index 53eb56e..3451f14 100644 --- a/src/components/project.vue +++ b/src/components/project.vue @@ -83,6 +83,9 @@ export default { }; }, inject: ['api', 'lang', 'hash', 'projects', 'user', 'consts', 'isMobile'], + beforeMount() { + if(this.hash.items.length == 0 && this.projects.getDefaultProject().mode == this.consts.modes.blog) this.hash.items[0] = this.projects.getDefaultCodeName(); + }, mounted() { this.init(); }, @@ -98,8 +101,8 @@ export default { 'hitchhiking': this.getStyleProperty('--track-hitchhiking') }; - if(!this.hash.items[0] || !this.projects[this.hash.items[0]]) await this.initProjectOverview(); - else await this.initProject(); + if(this.hash.items[0] && this.projects[this.hash.items[0]]) await this.initProject(); + else await this.initProjectOverview(); }, quit() { this.lightbox.end();