chore(react/settings): reimplement reset shortcuts

This commit is contained in:
Elian Doran
2025-08-18 19:47:40 +03:00
parent 227cf5de85
commit b97a5ef888
4 changed files with 36 additions and 6 deletions

View File

@@ -167,10 +167,9 @@ export function useTriliumOptions<T extends OptionNames>(...names: T[]) {
values[name] = options.get(name);
}
const setValue = (newValues: Record<T, string>) => server.put<void>("options", newValues);
return [
values as Record<T, string>,
setValue
options.saveMany
] as const;
}