implemented settings and user page (darkmode is still missing)

This commit is contained in:
2024-03-24 21:02:56 +01:00
parent acb7bb7cb6
commit 45a4b58f26
36 changed files with 2283 additions and 1313 deletions

View File

@ -91,9 +91,9 @@
<pre v-if="isExpanded" :class="['label', darkMode ? 'label-darkmode' : 'label-lightmode']">Instance</pre>
</Transition>
</button>
<router-link v-if="addSolutionIcon" to="/solutions" class="button" :class="[darkMode ? 'button-darkmode' : 'button-lightmode']" id="solutions-button">
<button :class="[darkMode ? 'button-darkmode' : 'button-lightmode']" id="new-solution"
@click="addSolution">
<router-link v-if="addSolutionIcon" to="/solutions" class="button"
:class="[darkMode ? 'button-darkmode' : 'button-lightmode']" id="solutions-button">
<button :class="[darkMode ? 'button-darkmode' : 'button-lightmode']" id="new-solution" @click="addSolution">
<div class="icon" id="new-icon">
<img :class="[darkMode ? 'img-darkmode' : 'img-lightmode']" loading="lazy"
src="/icons/actionbar-icons/Add-New-Icon.svg" />
@ -128,10 +128,11 @@
</template>
<script setup>
import { ref, onMounted } from 'vue';
import { ref, onMounted, watch } from 'vue';
import { useStore } from 'vuex';
import { computed } from 'vue';
const changeToSet = computed(() => store.state.changeToSet);
const addIcon = computed(() => store.state.addIcon);
const addInstanceIcon = computed(() => store.state.addInstanceIcon);
const addSolutionIcon = computed(() => store.state.addSolutionIcon);
@ -178,8 +179,22 @@ const changeToSolutions = () => {
store.commit('changeToSolutionlistAsset');
}
// const changeToSettingsPage = () => {
// store.commit('changeToSettings');
// if (changeToSet.value) {
// store.commit('toggleChangeToSet');
// }
// console.log('set')
// }
// watch(changeToSet, changeToSettingsPage)
onMounted(() => {
store.commit('changeToAssetlist')
if (changeToSet.value) {
store.commit('toggleChangeToSet');
store.commit('changeToSettings');
}
});
</script>