@vite-plugin-opencode-assistant/shared 1.0.27 → 1.0.28

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/es/types.d.ts CHANGED
@@ -121,6 +121,10 @@ export interface WidgetOptions {
121
121
  open: boolean;
122
122
  /** 快捷键配置 */
123
123
  hotkey?: string;
124
+ /** OpenCode 代理服务端口 */
125
+ proxyPort?: number;
126
+ /** OpenCode 代理服务主机名 */
127
+ proxyHost?: string;
124
128
  }
125
129
  /**
126
130
  * OpenCode 会话信息
@@ -199,6 +203,18 @@ export type OpenCodeWidgetTheme = "light" | "dark" | "auto";
199
203
  * 服务状态
200
204
  */
201
205
  export type ServiceStatus = "idle" | "starting" | "ready" | "partial" | "failed";
206
+ /**
207
+ * Session 状态类型
208
+ */
209
+ export type OpencodeSessionStatusType = "idle" | "running" | "streaming" | "completed";
210
+ /**
211
+ * Session 思考状态
212
+ */
213
+ export interface OpencodeSessionThinkingState {
214
+ thinking: boolean;
215
+ statusType: OpencodeSessionStatusType;
216
+ hasPending: boolean;
217
+ }
202
218
  /**
203
219
  * 挂件会话信息
204
220
  */
@@ -276,6 +292,8 @@ export interface OpenCodeWidgetProps {
276
292
  showClearAll?: boolean;
277
293
  selectEnabled?: boolean;
278
294
  thinking?: boolean;
295
+ /** 所有 session 的状态映射 */
296
+ sessionStates?: Record<string, OpencodeSessionThinkingState>;
279
297
  }
280
298
  /**
281
299
  * 挂件组件事件
package/lib/types.d.ts CHANGED
@@ -121,6 +121,10 @@ export interface WidgetOptions {
121
121
  open: boolean;
122
122
  /** 快捷键配置 */
123
123
  hotkey?: string;
124
+ /** OpenCode 代理服务端口 */
125
+ proxyPort?: number;
126
+ /** OpenCode 代理服务主机名 */
127
+ proxyHost?: string;
124
128
  }
125
129
  /**
126
130
  * OpenCode 会话信息
@@ -199,6 +203,18 @@ export type OpenCodeWidgetTheme = "light" | "dark" | "auto";
199
203
  * 服务状态
200
204
  */
201
205
  export type ServiceStatus = "idle" | "starting" | "ready" | "partial" | "failed";
206
+ /**
207
+ * Session 状态类型
208
+ */
209
+ export type OpencodeSessionStatusType = "idle" | "running" | "streaming" | "completed";
210
+ /**
211
+ * Session 思考状态
212
+ */
213
+ export interface OpencodeSessionThinkingState {
214
+ thinking: boolean;
215
+ statusType: OpencodeSessionStatusType;
216
+ hasPending: boolean;
217
+ }
202
218
  /**
203
219
  * 挂件会话信息
204
220
  */
@@ -276,6 +292,8 @@ export interface OpenCodeWidgetProps {
276
292
  showClearAll?: boolean;
277
293
  selectEnabled?: boolean;
278
294
  thinking?: boolean;
295
+ /** 所有 session 的状态映射 */
296
+ sessionStates?: Record<string, OpencodeSessionThinkingState>;
279
297
  }
280
298
  /**
281
299
  * 挂件组件事件
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vite-plugin-opencode-assistant/shared",
3
- "version": "1.0.27",
3
+ "version": "1.0.28",
4
4
  "type": "module",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",