@aipanel/provider-opencode 1.2.7 → 1.2.9
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/bridge-script.d.ts +3 -2
- package/es/bridge-script.js +1 -1
- package/es/opencode-web.js +3 -1
- package/lib/bridge-script.cjs +1 -1
- package/lib/bridge-script.d.ts +3 -2
- package/lib/opencode-web.cjs +1 -1
- package/package.json +2 -2
package/es/bridge-script.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { OpenCodeLanguage, OpenCodeSettings } from "./types";
|
|
2
|
+
import type { AIPanelWidgetTheme } from "@aipanel/core";
|
|
2
3
|
export interface BridgeScriptOptions {
|
|
3
|
-
/**
|
|
4
|
-
theme?:
|
|
4
|
+
/** 主题模式(单一来源:@aipanel/core AIPanelWidgetTheme) */
|
|
5
|
+
theme?: AIPanelWidgetTheme;
|
|
5
6
|
/** 界面语言 */
|
|
6
7
|
language?: OpenCodeLanguage;
|
|
7
8
|
/** 内部设置 */
|
package/es/bridge-script.js
CHANGED
|
@@ -522,7 +522,7 @@ function generateBridgeScript(options = {}) {
|
|
|
522
522
|
return;
|
|
523
523
|
}
|
|
524
524
|
|
|
525
|
-
const { filePath, line, column, description, innerText, previewPageUrl
|
|
525
|
+
const { filePath, line, column, description, innerText, previewPageUrl } = element;
|
|
526
526
|
|
|
527
527
|
const selector = description || 'element';
|
|
528
528
|
let textPreview = '';
|
package/es/opencode-web.js
CHANGED
|
@@ -4,8 +4,10 @@ import path from "path";
|
|
|
4
4
|
import { fileURLToPath, pathToFileURL } from "url";
|
|
5
5
|
import {
|
|
6
6
|
AIPANEL_CACHE_DIR,
|
|
7
|
+
DEFAULT_HOSTNAME,
|
|
7
8
|
MCP_API_PATH,
|
|
8
9
|
VSCODE_EXTENSION_PORT,
|
|
10
|
+
VSCODE_ROUTE_HEALTH,
|
|
9
11
|
ENV_VSCODE_PORT,
|
|
10
12
|
createLogger,
|
|
11
13
|
getProcessLogBuffer,
|
|
@@ -181,7 +183,7 @@ function isFormatServiceRunning() {
|
|
|
181
183
|
if (_formatServiceRunning !== void 0) return _formatServiceRunning;
|
|
182
184
|
try {
|
|
183
185
|
require2("child_process").execSync(
|
|
184
|
-
`node -e "const h=require('http');h.get('http
|
|
186
|
+
`node -e "const h=require('http');h.get('http://${DEFAULT_HOSTNAME}:${VSCODE_EXTENSION_PORT}${VSCODE_ROUTE_HEALTH}',r=>{r.resume();process.exit(r.statusCode===200?0:1)}).on('error',()=>process.exit(1))"`,
|
|
185
187
|
{ timeout: 500, stdio: "ignore" }
|
|
186
188
|
);
|
|
187
189
|
_formatServiceRunning = true;
|
package/lib/bridge-script.cjs
CHANGED
|
@@ -544,7 +544,7 @@ function generateBridgeScript(options = {}) {
|
|
|
544
544
|
return;
|
|
545
545
|
}
|
|
546
546
|
|
|
547
|
-
const { filePath, line, column, description, innerText, previewPageUrl
|
|
547
|
+
const { filePath, line, column, description, innerText, previewPageUrl } = element;
|
|
548
548
|
|
|
549
549
|
const selector = description || 'element';
|
|
550
550
|
let textPreview = '';
|
package/lib/bridge-script.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { OpenCodeLanguage, OpenCodeSettings } from "./types";
|
|
2
|
+
import type { AIPanelWidgetTheme } from "@aipanel/core";
|
|
2
3
|
export interface BridgeScriptOptions {
|
|
3
|
-
/**
|
|
4
|
-
theme?:
|
|
4
|
+
/** 主题模式(单一来源:@aipanel/core AIPanelWidgetTheme) */
|
|
5
|
+
theme?: AIPanelWidgetTheme;
|
|
5
6
|
/** 界面语言 */
|
|
6
7
|
language?: OpenCodeLanguage;
|
|
7
8
|
/** 内部设置 */
|
package/lib/opencode-web.cjs
CHANGED
|
@@ -207,7 +207,7 @@ function isFormatServiceRunning() {
|
|
|
207
207
|
if (_formatServiceRunning !== void 0) return _formatServiceRunning;
|
|
208
208
|
try {
|
|
209
209
|
require2("child_process").execSync(
|
|
210
|
-
`node -e "const h=require('http');h.get('http
|
|
210
|
+
`node -e "const h=require('http');h.get('http://${import_node.DEFAULT_HOSTNAME}:${import_node.VSCODE_EXTENSION_PORT}${import_node.VSCODE_ROUTE_HEALTH}',r=>{r.resume();process.exit(r.statusCode===200?0:1)}).on('error',()=>process.exit(1))"`,
|
|
211
211
|
{ timeout: 500, stdio: "ignore" }
|
|
212
212
|
);
|
|
213
213
|
_formatServiceRunning = true;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aipanel/provider-opencode",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.9",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "lib/index.cjs",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"@opencode-ai/plugin": "^1.18.0",
|
|
25
25
|
"execa": "^9.6.1",
|
|
26
|
-
"@aipanel/core": "1.2.
|
|
26
|
+
"@aipanel/core": "1.2.9"
|
|
27
27
|
},
|
|
28
28
|
"scripts": {
|
|
29
29
|
"build": "pagoda-cli build",
|