1
0
silverbullet/web/syscalls/sync.ts
2023-07-14 13:44:30 +02:00

14 lines
412 B
TypeScript

import { SysCallMapping } from "../../plugos/system.ts";
import type { Editor } from "../editor.tsx";
export function syncSyscalls(editor: Editor): SysCallMapping {
return {
"sync.isSyncing": (): Promise<boolean> => {
return editor.syncService.isSyncing();
},
"sync.hasInitialSyncCompleted": (): Promise<boolean> => {
return editor.syncService.hasInitialSyncCompleted();
},
};
}