@feedmepos/mf-miniprogram-v2 0.1.0-dev.12 → 0.1.0-dev.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/app.js
CHANGED
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@feedmepos/mf-miniprogram-v2",
|
|
3
|
-
"version": "0.1.0-dev.
|
|
3
|
+
"version": "0.1.0-dev.14",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public",
|
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
"@feedmepos/mf-common": "^1.27.9",
|
|
40
40
|
"@feedmepos/ui-library": "1.8.4",
|
|
41
41
|
"@opencode-ai/sdk": "*",
|
|
42
|
+
"diff": "^9.0.0",
|
|
42
43
|
"dompurify": "^3.4.11",
|
|
43
44
|
"highlight.js": "^11.11.1",
|
|
44
45
|
"marked": "^18.0.5",
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ChatMessage } from '../composables/types';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
files: string[];
|
|
4
|
+
diffs: ChatMessage['diffs'];
|
|
5
|
+
loading?: boolean;
|
|
6
|
+
};
|
|
7
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
8
|
+
declare const _default: typeof __VLS_export;
|
|
9
|
+
export default _default;
|
|
@@ -1,4 +1,16 @@
|
|
|
1
1
|
import type { ToolState } from '@opencode-ai/sdk';
|
|
2
|
+
/** OpenCode 1.17.14's server emits a unified `patch`, while the generated SDK
|
|
3
|
+
* still declares the older `before`/`after` shape. Keep both so current and
|
|
4
|
+
* already-archived sessions render through the same UI. */
|
|
5
|
+
export interface CodeFileDiff {
|
|
6
|
+
file: string;
|
|
7
|
+
patch?: string;
|
|
8
|
+
status?: 'added' | 'deleted' | 'modified';
|
|
9
|
+
before?: string;
|
|
10
|
+
after?: string;
|
|
11
|
+
additions: number;
|
|
12
|
+
deletions: number;
|
|
13
|
+
}
|
|
2
14
|
export type ChatPart = {
|
|
3
15
|
kind: 'text';
|
|
4
16
|
id: string;
|
|
@@ -35,8 +47,16 @@ export interface ChatMessage {
|
|
|
35
47
|
key: string;
|
|
36
48
|
id: string | null;
|
|
37
49
|
role: 'user' | 'assistant';
|
|
50
|
+
/** Assistant messages point back to the user turn that spawned them. OpenCode
|
|
51
|
+
* stores the turn's final file diff on that user message, so this relation
|
|
52
|
+
* lets the UI render it beside the agent work that produced it. */
|
|
53
|
+
parentId: string | null;
|
|
38
54
|
createdAt: number;
|
|
39
55
|
parts: ChatPart[];
|
|
56
|
+
/** Patch parts arrive before the complete before/after diff is summarized.
|
|
57
|
+
* Keep their file names so the UI can show useful live progress. */
|
|
58
|
+
changedFiles: string[];
|
|
59
|
+
diffs: CodeFileDiff[];
|
|
40
60
|
busy: boolean;
|
|
41
61
|
errorText?: string;
|
|
42
62
|
}
|