()
| 99 | } |
| 100 | |
| 101 | async function loadDocumentFlowNavigationModule() { |
| 102 | const tempRoot = join(process.cwd(), ".tmp"); |
| 103 | mkdirSync(tempRoot, { recursive: true }); |
| 104 | const dir = mkdtempSync(join(tempRoot, "lessai-document-flow-navigation-")); |
| 105 | |
| 106 | try { |
| 107 | const source = read("src/stages/workbench/document/documentFlowNavigation.ts"); |
| 108 | const transpiled = ts.transpileModule(source, { |
| 109 | compilerOptions: { |
| 110 | module: ts.ModuleKind.ES2022, |
| 111 | target: ts.ScriptTarget.ES2022 |
| 112 | }, |
| 113 | fileName: "documentFlowNavigation.ts" |
| 114 | }).outputText; |
| 115 | const rewritten = rewriteRelativeImports(transpiled); |
| 116 | writeFileSync(join(dir, "documentFlowNavigation.mjs"), rewritten, "utf8"); |
| 117 | |
| 118 | return await import(pathToFileURL(join(dir, "documentFlowNavigation.mjs")).href); |
| 119 | } finally { |
| 120 | rmSync(dir, { recursive: true, force: true }); |
| 121 | } |
| 122 | } |
| 123 | |
| 124 | async function loadHelpersModule() { |
| 125 | const tempRoot = join(process.cwd(), ".tmp"); |
no test coverage detected