mirror of
https://github.com/zadam/trilium.git
synced 2025-11-01 02:45:54 +01:00
refactor(bulk_action): full type safety for client
This commit is contained in:
@@ -44,4 +44,6 @@ export type ActionHandlers = {
|
||||
|
||||
export type BulkActionData<T extends keyof ActionHandlers> = ActionHandlers[T] & { name: T };
|
||||
|
||||
export type BulkAction = BulkActionData<keyof ActionHandlers>;
|
||||
export type BulkAction = {
|
||||
[K in keyof ActionHandlers]: { name: K; } & ActionHandlers[K];
|
||||
}[keyof ActionHandlers];
|
||||
|
||||
Reference in New Issue
Block a user