diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 4bfe3b9..7b282d6 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -15,6 +15,10 @@ updates: - xixu-me commit-message: prefix: 'deps(bun)' + ignore: + - dependency-name: typescript + update-types: + - version-update:semver-major groups: web-and-tooling: update-types: diff --git a/apps/web/src/lib/download/zip.ts b/apps/web/src/lib/download/zip.ts index 89275be..ed9654d 100644 --- a/apps/web/src/lib/download/zip.ts +++ b/apps/web/src/lib/download/zip.ts @@ -2,7 +2,7 @@ * ZIP creation helpers for download-all flows and small generated archives. */ -import { TextReader, Uint8ArrayReader, Uint8ArrayWriter, ZipWriter } from '@zip.js/zip.js' +import { Uint8ArrayReader, Uint8ArrayWriter, ZipWriter } from '@zip.js/zip.js' import { sanitizePath } from '@/lib/files/paths' @@ -63,7 +63,7 @@ export async function buildZipFromStreams(entries: ZipStreamEntryInput[]) { /** buildTextZip creates a small ZIP archive containing one UTF-8 text file. */ export async function buildTextZip(path: string, content: string) { const writer = new ZipWriter(new Uint8ArrayWriter()) - await writer.add(sanitizePath(path), new TextReader(content)) + await writer.add(sanitizePath(path), new Uint8ArrayReader(new TextEncoder().encode(content))) const bytes = await writer.close() return new Blob([bytes.buffer.slice(bytes.byteOffset, bytes.byteOffset + bytes.byteLength)], { type: 'application/zip',