Extracted syscall packages
This commit is contained in:
@@ -36,6 +36,9 @@ export default (editor: Editor): SysCallMapping => ({
|
||||
getCursor: (): number => {
|
||||
return editor.editorView!.state.selection.main.from;
|
||||
},
|
||||
save: async () => {
|
||||
return editor.save(true);
|
||||
},
|
||||
navigate: async (ctx, name: string, pos: number) => {
|
||||
await editor.navigate(name, pos);
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Editor } from "../editor";
|
||||
import { PageMeta } from "../types";
|
||||
import { SysCallMapping } from "../../plugos/system";
|
||||
import { PageMeta } from "../../common/types";
|
||||
|
||||
export default (editor: Editor): SysCallMapping => ({
|
||||
listPages: async (): Promise<PageMeta[]> => {
|
||||
|
||||
Reference in New Issue
Block a user