Add projects to settings panel

This commit is contained in:
2024-02-17 00:17:20 +01:00
parent 6e614042d1
commit 59dea2917d
9 changed files with 183 additions and 164 deletions

View File

@@ -13,6 +13,11 @@ export default {
hash: {}
};
},
provide() {
return {
projects: this.spot.vars('projects')
};
},
inject: ['spot'],
computed: {
page() {
@@ -36,7 +41,10 @@ export default {
},
onHashChange() {
let asHash = this.getHash();
if(asHash.hash !='' && asHash.page != '') this.hash = asHash;
if(asHash.hash !='' && asHash.page != '') {
if(asHash.page == this.hash.page) this.spot.onSamePageMove(asHash);
this.hash = asHash;
}
else if(!this.hash.page) this.setHash(this.spot.consts.default_page);
},
getHash() {