fix: add web project folder picker and isolated HTML file previews
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { PreviewManager } from '../core/preview/preview-manager.mjs';
|
||||
import { LocalFilePreviews } from '../core/preview/local-file-preview.mjs';
|
||||
import { BrowsingManager } from '../core/browser/browsing-manager.mjs';
|
||||
import { browsingToolDefinitions, browsingAction } from '../shared/contracts/browsing.mjs';
|
||||
import { publicEnvironmentDiagnostic } from '../core/environment/environment-manager.mjs';
|
||||
@@ -132,6 +133,7 @@ export class Runtime {
|
||||
redact: value => this.provider.redact(value), projectBusy: (projectId, exceptId) => this.projectHasActivity(projectId, exceptId) }); }
|
||||
previewManager() { return this.previews ??= new PreviewManager(this.store, { runtimeDirectory: this.appDirectory ? path.join(this.appDirectory, 'runtime') : null,
|
||||
redact: value => this.provider.redact(value), projectBusy: projectId => this.projectHasActivity(projectId) }); }
|
||||
localFilePreviews() { return this.filePreviews ??= new LocalFilePreviews(this.store); }
|
||||
browsingManager() { return this.browsing ??= new BrowsingManager(this.store, { redact: value => this.provider.redact(value), workbenchOrigin: this.workbenchOrigin }); }
|
||||
engineManager() {
|
||||
return this.engines ??= new EngineManager(this.store, { appDirectory: this.appDirectory,
|
||||
@@ -794,5 +796,5 @@ export class Runtime {
|
||||
run.controller.abort(new Error('用户停止任务'));
|
||||
await run.promise;
|
||||
}
|
||||
async stopAll() { await this.browsing?.stopAll(); await this.previews?.stopAll(); await this.evaluations?.stopAll(); await this.workers?.stopAll(); await Promise.all([...this.active.keys()].map(id => this.stop(id))); await this.controlledEngines?.stopAll(); await this.environments?.stopAll(); await this.checks?.stopAll(); await this.deliveries?.stopAll(); await this.changeSets?.stopAll(); await this.workspaces?.stopAll(); await this.research?.stopAll(); await this.engines?.stopAll(); await this.browser?.stopAll(); await this.mcp?.stopAll(); await this.taskPlans?.settle(); }
|
||||
async stopAll() { await this.filePreviews?.stopAll(); await this.browsing?.stopAll(); await this.previews?.stopAll(); await this.evaluations?.stopAll(); await this.workers?.stopAll(); await Promise.all([...this.active.keys()].map(id => this.stop(id))); await this.controlledEngines?.stopAll(); await this.environments?.stopAll(); await this.checks?.stopAll(); await this.deliveries?.stopAll(); await this.changeSets?.stopAll(); await this.workspaces?.stopAll(); await this.research?.stopAll(); await this.engines?.stopAll(); await this.browser?.stopAll(); await this.mcp?.stopAll(); await this.taskPlans?.settle(); }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user