11<template >
22 <v-app-bar color =" primary" prominent >
3- <v-app-bar-nav-icon variant =" text" @click.stop =" drawer = !drawer" ></v-app-bar-nav-icon >
3+ <v-app-bar-nav-icon
4+ variant =" text"
5+ @click.stop =" drawer = !drawer"
6+ ></v-app-bar-nav-icon >
47
58 <v-toolbar-title >ProA – {{ currentRouteName }}</v-toolbar-title >
69
1215 <v-icon icon =" mdi-account-circle" ></v-icon >
1316 </v-btn >
1417 </template >
15- {{ $t(' general.myProfile' ) }}
18+ {{ $t(" general.myProfile" ) }}
1619 </v-tooltip >
1720
18- <v-tooltip location =" bottom" v-if =" webVersion && isUserLoggedIn && isUserAdmin" >
21+ <v-tooltip
22+ location =" bottom"
23+ v-if =" webVersion && isUserLoggedIn && isUserAdmin"
24+ >
1925 <template v-slot :activator =" { props } " >
20- <v-btn v-bind =" props" @click =" openDialog(SelectedDialog.CREATE_ACCOUNT)" >
26+ <v-btn
27+ v-bind =" props"
28+ @click =" openDialog(SelectedDialog.CREATE_ACCOUNT)"
29+ >
2130 <v-icon icon =" mdi-account-plus" ></v-icon >
2231 </v-btn >
2332 </template >
24- {{ $t(' navigation.createAccount' ) }}
33+ {{ $t(" navigation.createAccount" ) }}
2534 </v-tooltip >
2635
27- <v-tooltip location =" bottom" v-if =" webVersion && isUserLoggedIn && isUserAdmin" >
36+ <v-tooltip
37+ location =" bottom"
38+ v-if =" webVersion && isUserLoggedIn && isUserAdmin"
39+ >
2840 <template v-slot :activator =" { props } " >
2941 <v-btn v-bind =" props" @click =" $router.push('/ManageUsers')" >
3042 <v-icon icon =" mdi-account-multiple" ></v-icon >
3143 </v-btn >
3244 </template >
33- {{ $t(' navigation.manageUsers' ) }}
45+ {{ $t(" navigation.manageUsers" ) }}
3446 </v-tooltip >
3547
3648 <v-tooltip location =" bottom" v-if =" webVersion && isUserLoggedIn" >
3951 <v-icon icon =" mdi-logout" ></v-icon >
4052 </v-btn >
4153 </template >
42- {{ $t('general.' +
43- 'signOut') }}
54+ {{ $t("general." + "signOut") }}
4455 </v-tooltip >
4556
4657 <v-menu >
4758 <template v-slot :activator =" { props } " >
48- <v-btn
49- color =" white"
50- variant =" text"
51- v-bind =" props"
52- >
59+ <v-btn color =" white" variant =" text" v-bind =" props" >
5360 {{ selectedLanguage.toUpperCase() }}
5461 </v-btn >
5562 </template >
6572 </v-list >
6673 </v-menu >
6774
68- <v-tooltip :text =" $t('general.settings')" location =" bottom" >
75+ <v-tooltip
76+ v-if =" isUserLoggedIn"
77+ :text =" $t('general.settings')"
78+ location =" bottom"
79+ >
6980 <template v-slot :activator =" { props } " >
7081 <v-btn icon v-bind =" props" @click =" toggleSettings" >
7182 <v-icon >mdi-cog</v-icon >
7586 </v-app-bar >
7687
7788 <v-navigation-drawer v-model =" drawer" location =" left" temporary >
78- <v-list
79- flat dense nav class =" py-1 px-0"
80- >
89+ <v-list flat dense nav class =" py-1 px-0" >
8190 <v-list-item
8291 @click =" $router.push({ path: item.route })"
8392 v-for =" item in items"
8493 :key =" item.title"
8594 dense
86- :disabled =" !store.getSelectedProjectId() && item.title !== $t('navigation.projectOverview')"
95+ :disabled ="
96+ !store.getSelectedProjectId() &&
97+ item.title !== $t('navigation.projectOverview')
98+ "
8799 class =" px-2"
88100 >
89- <v-list-item-title class =" text-body-1 font-weight-regular" >{{ item.title }}</v-list-item-title >
101+ <v-list-item-title class =" text-body-1 font-weight-regular" >{{
102+ item.title
103+ }}</v-list-item-title >
90104 </v-list-item >
91105 </v-list >
92106 </v-navigation-drawer >
93107
94- <SettingsDrawer />
95-
96- <AuthenticationDialog v-if =" webVersion" />
108+ <SettingsDrawer />
97109
110+ <AuthenticationDialog v-if =" webVersion" />
98111</template >
99112
100- <style scoped>
101- </style >
113+ <style scoped></style >
102114
103115<script lang="ts">
104- import { defineComponent } from ' vue'
105- import { useAppStore } from " @/store/app" ;
116+ import { defineComponent } from " vue" ;
117+ import { SelectedDialog , useAppStore } from " @/store/app" ;
106118import SettingsDrawer from " @/components/SettingsDrawer.vue" ;
107119import i18n from " @/i18n" ;
108120import AuthenticationDialog from " @/components/Authentication/AuthenticationDialog.vue" ;
109- import { SelectedDialog } from " @/store/app" ;
110121import { Role } from " @/components/ProcessMap/types" ;
111122
112- export type LanguageCode = ' en ' | ' de ' ;
123+ export type LanguageCode = " en " | " de " ;
113124
114125interface Language {
115- code: LanguageCode
116- name: string
126+ code: LanguageCode ;
127+ name: string ;
117128}
118129
119130export default defineComponent ({
@@ -126,7 +137,7 @@ export default defineComponent({
126137 },
127138 lowerFirstLetter(s : string | undefined ) {
128139 if (! s ) {
129- return ' ' ;
140+ return " " ;
130141 }
131142 return s .charAt (0 ).toLowerCase () + s .slice (1 );
132143 },
@@ -150,12 +161,12 @@ export default defineComponent({
150161 drawer: false as boolean ,
151162 group: null ,
152163 selectedLanguage: store .getSelectedLanguage () as LanguageCode ,
153- webVersion: (import .meta .env .VITE_APP_MODE === ' web' ) as boolean ,
164+ webVersion: (import .meta .env .VITE_APP_MODE === " web" ) as boolean ,
154165 showEditDialog: false as boolean ,
155166 showProfileDialog: false as boolean ,
156167 showProfileSuccessMessage: false as boolean ,
157168 SelectedDialog: SelectedDialog
158- }
169+ };
159170 },
160171
161172 async mounted() {
@@ -169,38 +180,42 @@ export default defineComponent({
169180 availableLanguages(): Language [] {
170181 const availableLanguages: Language [] = [
171182 {
172- code: ' de ' ,
173- name: this .$t (' general.german' )
183+ code: " de " ,
184+ name: this .$t (" general.german" )
174185 },
175186 {
176- code: ' en ' ,
177- name: this .$t (' general.english' )
187+ code: " en " ,
188+ name: this .$t (" general.english" )
178189 }
179190 ];
180- return availableLanguages .sort ((language1 , language2 ) => language1 .name .localeCompare (language2 .name ));
191+ return availableLanguages .sort ((language1 , language2 ) =>
192+ language1 .name .localeCompare (language2 .name )
193+ );
181194 },
182195 items() {
183196 return [
184197 {
185- title: this .$t (' navigation.projectOverview' ),
186- route: ' / '
198+ title: this .$t (" navigation.projectOverview" ),
199+ route: " / "
187200 },
188201 {
189- title: this .$t (' navigation.processList' ),
190- route: ' /ProcessList'
202+ title: this .$t (" navigation.processList" ),
203+ route: " /ProcessList"
191204 },
192205 {
193- title: this .$t (' navigation.c8Import' ),
194- route: ' /CamundaCloudImport'
206+ title: this .$t (" navigation.c8Import" ),
207+ route: " /CamundaCloudImport"
195208 },
196209 {
197- title: this .$t (' navigation.processMap' ),
198- route: ' /ProcessMap'
210+ title: this .$t (" navigation.processMap" ),
211+ route: " /ProcessMap"
199212 }
200213 ];
201214 },
202215 currentRouteName() {
203- return this .$t (' navigation.' + this .lowerFirstLetter (this .$route .name ?.toString ()));
216+ return this .$t (
217+ " navigation." + this .lowerFirstLetter (this .$route .name ?.toString ())
218+ );
204219 },
205220 isUserLoggedIn() {
206221 return this .store .getUserToken () != null ;
@@ -212,8 +227,8 @@ export default defineComponent({
212227
213228 watch: {
214229 group() {
215- this .drawer = false
230+ this .drawer = false ;
216231 }
217232 }
218- })
233+ });
219234 </script >
0 commit comments