66 <template #prepend >
77 <v-icon icon =" mdi-home" ></v-icon >
88 </template >
9- <v-list-item-title >Home</v-list-item-title >
9+ <SkMouseTrapToolTip hotkey =" g h" command =" Go to Home" highlight-effect =" none" position =" right" >
10+ <v-list-item-title >Home</v-list-item-title >
11+ </SkMouseTrapToolTip >
1012 </v-list-item >
1113
1214 <v-list-item to =" /study" value =" study" >
1315 <template #prepend >
1416 <v-icon icon =" mdi-school" ></v-icon >
1517 </template >
16- <v-list-item-title >Study</v-list-item-title >
18+ <SkMouseTrapToolTip hotkey =" g s" command =" Go to Study" highlight-effect =" none" position =" right" >
19+ <v-list-item-title >Study</v-list-item-title >
20+ </SkMouseTrapToolTip >
1721 </v-list-item >
1822
1923 <v-list-item to =" /classrooms" value =" classrooms" >
2024 <template #prepend >
2125 <v-icon icon =" mdi-account-group" ></v-icon >
2226 </template >
23- <v-list-item-title >Classrooms</v-list-item-title >
27+ <SkMouseTrapToolTip hotkey =" g c" command =" Go to Classrooms" highlight-effect =" none" position =" right" >
28+ <v-list-item-title >Classrooms</v-list-item-title >
29+ </SkMouseTrapToolTip >
2430 </v-list-item >
2531
2632 <v-list-item to =" /quilts" value =" quilts" >
2733 <template #prepend >
2834 <v-icon icon =" mdi-bookmark-multiple" ></v-icon >
2935 </template >
30- <v-list-item-title >Quilts</v-list-item-title >
36+ <SkMouseTrapToolTip hotkey =" g q" command =" Go to Quilts" highlight-effect =" none" position =" right" >
37+ <v-list-item-title >Quilts</v-list-item-title >
38+ </SkMouseTrapToolTip >
3139 </v-list-item >
3240 </v-list >
3341 </v-navigation-drawer >
5462 </span>
5563 </v-footer> -->
5664 <snackbar-service id =" SnackbarService" />
65+ <SkMouseTrap />
66+
67+ <v-footer app class =" pa-0" color =" transparent" >
68+ <v-card flat width =" 100%" class =" text-center" >
69+ <v-card-text class =" text-body-2 text-medium-emphasis" >
70+ <v-icon small class =" me-1" >mdi-keyboard</v-icon >
71+ Tip: Hold <kbd >Ctrl</kbd > to see keyboard shortcuts or press <kbd >?</kbd > to view all shortcuts
72+ </v-card-text >
73+ </v-card >
74+ </v-footer >
5775 </v-app >
5876</template >
5977
@@ -63,6 +81,9 @@ import { useTheme } from 'vuetify';
6381import {
6482 UserLoginAndRegistrationContainer ,
6583 SnackbarService ,
84+ SkMouseTrapToolTip ,
85+ SkMouseTrap ,
86+ SkldrMouseTrap ,
6687 useConfigStore ,
6788 useAuthStore ,
6889} from ' @vue-skuilder/common-ui' ;
@@ -110,6 +131,20 @@ onBeforeMount(async () => {
110131
111132onMounted (async () => {
112133 latestBuild .value = ' buildValue not implemented' ;
134+
135+ // Add a global shortcut to show the keyboard shortcuts dialog
136+ SkldrMouseTrap .bind ([
137+ {
138+ hotkey: ' ?' ,
139+ command: ' Show keyboard shortcuts' ,
140+ callback : () => {
141+ const keyboardButton = document .querySelector (' .mdi-keyboard' );
142+ if (keyboardButton ) {
143+ (keyboardButton as HTMLElement ).click ();
144+ }
145+ }
146+ }
147+ ]);
113148});
114149 </script >
115150
0 commit comments