test(f7.1): host E2E — changed flowchart augments emitted source (#22)
Adds a renderHtmlFor test seam to TrackChangesPreviewController. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -214,6 +214,14 @@ export class TrackChangesPreviewController implements vscode.Disposable {
|
||||
getLastModel(uriString: string): BlockOp[] | undefined {
|
||||
return this.lastModel.get(uriString);
|
||||
}
|
||||
/** F7.1 (#22) test seam: the track-changes HTML the panel would post for a doc. */
|
||||
renderHtmlFor(uriString: string): string {
|
||||
const doc = vscode.workspace.textDocuments.find((d) => d.uri.toString() === uriString);
|
||||
if (!doc) return "";
|
||||
const current = doc.getText();
|
||||
const baseline = this.diffView.getBaseline(uriString);
|
||||
return renderTrackChanges(baseline?.text ?? current, current);
|
||||
}
|
||||
/** F9: current view mode for a panel (default track-changes). */
|
||||
getMode(uriString: string): "changes" | "authorship" {
|
||||
return this.mode.get(uriString) ?? "changes";
|
||||
|
||||
Reference in New Issue
Block a user