Improved shortcuts handling

This commit is contained in:
the-djmaze 2022-02-25 17:02:08 +01:00
parent 65a3b9e4c7
commit 1d63683cf9
7 changed files with 28 additions and 50 deletions

View file

@ -16,15 +16,11 @@ addObservablesTo(AppUserStore, {
});
AppUserStore.focusedState.subscribe(value => {
switch (value) {
case Scope.MessageList:
case Scope.MessageView:
case Scope.FolderList:
['FolderList','MessageList','MessageView'].forEach(name => {
if (name === value) {
keyScope(value);
ThemeStore.isMobile() && leftPanelDisabled(Scope.FolderList !== value);
break;
}
['FolderList','MessageList','MessageView'].forEach(name => {
}
let dom = elementById('V-Mail'+name);
dom && dom.classList.toggle('focused', name === value);
});