taskgenius_taskgenius-plugin/src/dataflow/parsers/CanvasEntry.ts
Quorafind 8c256a94c4 refactor(dataflow): reorganize workers and fix import paths
- Move worker managers from utils to dataflow/workers directory
- Fix all import paths to use correct relative references
- Add storage API fixes documentation
- Add TaskIndexer migration plan documentation
- Create bridge classes for MCP server integration
- Extract shared utilities to utils directory (filterUtils, projectFilter, etc.)
- Fix type issues in QueryAPI and Augmentor
- Ensure all worker imports use correct paths
- Improve separation between dataflow and legacy code

This completes the dataflow architecture reorganization to have
cleaner boundaries between the new dataflow system and legacy code.
2025-08-19 07:35:59 +08:00

14 lines
692 B
TypeScript

import { CanvasParser } from "../../dataflow/core/CanvasParser";
import type { Task } from "../../types/task";
import { getConfig } from "../../common/task-parser-config";
import TaskProgressBarPlugin from "../../index";
// This entry requires plugin to provide config like original code did
export async function parseCanvas(plugin: TaskProgressBarPlugin, file: { path: string }, content?: string): Promise<Task[]> {
const config = getConfig(plugin.settings.preferMetadataFormat, plugin);
const parser = new CanvasParser(config);
const filePath = file.path;
const text = content ?? await plugin.app.vault.cachedRead(file as any);
return parser.parseCanvasFile(text, filePath);
}