fix(files): keep large source previews responsive (#3665)

Large read-only files bypassed the editor's virtualization and eagerly mounted every highlighted token, which could stall the renderer for seconds and consume gigabytes of memory. Route source previews through bounded platform renderers and reject reads above their display budgets before accumulation.
This commit is contained in:
Mohamed Boudra
2026-08-22 10:13:31 +02:00
committed by GitHub
parent 8905ad4160
commit c763b80824
22 changed files with 589 additions and 183 deletions
+1
View File
@@ -2555,6 +2555,7 @@ export const FileExplorerRequestSchema = z.object({
mode: z.enum(["list", "file"]),
requestId: z.string(),
acceptBinary: z.boolean().optional(),
maxBytes: z.number().int().positive().optional(),
});
export const FileVersionSchema = z.discriminatedUnion("status", [