From a1d7e81859f554f3a53680cc35f0f49bf1f77098 Mon Sep 17 00:00:00 2001
From: wwf <1971391498@qq.com>
Date: 星期四, 14 五月 2026 14:37:02 +0800
Subject: [PATCH] 导入项目

---
 src/components/Tinyflow/ui/index.d.ts |   41 +++++++++++++++++++++++++++++++++++++++++
 1 files changed, 41 insertions(+), 0 deletions(-)

diff --git a/src/components/Tinyflow/ui/index.d.ts b/src/components/Tinyflow/ui/index.d.ts
new file mode 100644
index 0000000..38a3132
--- /dev/null
+++ b/src/components/Tinyflow/ui/index.d.ts
@@ -0,0 +1,41 @@
+import { Edge } from '@xyflow/svelte';
+import { Node as Node_2 } from '@xyflow/svelte';
+import { useSvelteFlow } from '@xyflow/svelte';
+import { Viewport } from '@xyflow/svelte';
+
+export declare type Item = {
+    value: number | string;
+    label: string;
+    children?: Item[];
+};
+
+export declare class Tinyflow {
+    private options;
+    private rootEl;
+    private svelteFlowInstance;
+    constructor(options: TinyflowOptions);
+    private _init;
+    private _setOptions;
+    getOptions(): TinyflowOptions;
+    getData(): {
+        nodes: Node_2[];
+        edges: Edge[];
+        viewport: Viewport;
+    };
+    setData(data: TinyflowData): void;
+    destroy(): void;
+}
+
+export declare type TinyflowData = Partial<ReturnType<ReturnType<typeof useSvelteFlow>['toObject']>>;
+
+export declare type TinyflowOptions = {
+    element: string | Element;
+    data?: TinyflowData;
+    provider?: {
+        llm?: () => Item[] | Promise<Item[]>;
+        knowledge?: () => Item[] | Promise<Item[]>;
+        internal?: () => Item[] | Promise<Item[]>;
+    };
+};
+
+export { }

--
Gitblit v1.8.0