fix prettier/lint

This commit is contained in:
Kendall Garner 2024-08-23 08:19:27 -07:00
parent 121b036aaf
commit 271be93a96
No known key found for this signature in database
GPG key ID: 18D2767419676C87
26 changed files with 133 additions and 103 deletions

View file

@ -34,8 +34,8 @@ export const ThemeSettings = () => {
e.currentTarget.checked
? 'system'
: settings.theme === AppTheme.DEFAULT_DARK
? 'dark'
: 'light',
? 'dark'
: 'light',
);
}
}}

View file

@ -200,18 +200,21 @@ export const HotkeyManagerSettings = () => {
);
const duplicateHotkeyMap = useMemo(() => {
const countPerHotkey = Object.values(bindings).reduce((acc, key) => {
const hotkey = key.hotkey;
if (!hotkey) return acc;
const countPerHotkey = Object.values(bindings).reduce(
(acc, key) => {
const hotkey = key.hotkey;
if (!hotkey) return acc;
if (acc[hotkey]) {
acc[hotkey] += 1;
} else {
acc[hotkey] = 1;
}
if (acc[hotkey]) {
acc[hotkey] += 1;
} else {
acc[hotkey] = 1;
}
return acc;
}, {} as Record<string, number>);
return acc;
},
{} as Record<string, number>,
);
const duplicateKeys = Object.keys(countPerHotkey).filter((key) => countPerHotkey[key] > 1);