authorgravatar for 269035359+t3-code[bot]@users.noreply.github.comt3-code[bot] <269035359+t3-code[bot]@users.noreply.github.com> 2026-08-20 03:11:20-04:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2026-08-20 03:11:20-04:00
logbeab6886f45bf42906d0bd01aefe5dfe9e66a867
treea32786a610f4d06a371a7bc299fea8d967948835
parentf708f63fa9bcd7e51f1f62531f6f9ed966b71807
signature Signed by PGP key B5690EEEBB952194

fix(web): import dependency-heavy Open VSX themes (#7642)

Co-authored-by: t3-code[bot] <269035359+t3-code[bot]@users.noreply.github.com> Co-authored-by: maria <254055478+maria-rcks@users.noreply.github.com>

2 files changed, 7 insertions(+), 2 deletions(-)

apps/web/src/openVsxThemes.test.ts+5
......@@ -293,6 +293,11 @@ describe("Open VSX themes", () => {
293293 it("downloads a verified VSIX, reads JSONC includes, and pairs contributed variants", async () => {
294294 const zip = new JSZip();
295295 zip.file("extension/.gitkeep", "");
296 // Theme extensions sometimes publish their development dependencies too.
297 // Those unused files should not prevent importing the small theme payload.
298 for (let index = 0; index < 3_000; index += 1) {
299 zip.file(`extension/node_modules/package-${index}.js`, "");
300 }
296301 zip.file(
297302 "extension/themes/base.jsonc",
298303 `{
apps/web/src/openVsxThemes.ts+2-2
......@@ -17,8 +17,8 @@ const MAX_DETAIL_BYTES = 256 * 1024;
1717const MAX_MANIFEST_BYTES = 256 * 1024;
1818const SEARCH_REQUEST_TIMEOUT_MS = 10_000;
1919const MAX_THEME_BYTES = 256 * 1024;
20const MAX_ZIP_ENTRIES = 2_000;
21const MAX_UNCOMPRESSED_BYTES = 50 * 1024 * 1024;
20const MAX_ZIP_ENTRIES = 5_000;
21const MAX_UNCOMPRESSED_BYTES = 100 * 1024 * 1024;
2222const MAX_COMPRESSION_RATIO = 200;
2323const MAX_THEMES_PER_EXTENSION = 40;
2424const MAX_INCLUDE_DEPTH = 8;