Add ZIP export and improve TeX distribution installation - #4
Merged
Francy2009 merged 2 commits intoAug 10, 2026
Merged
Conversation
The old yihui.org/tinytex/TinyTeX-1.zip link now 404s, so the LaTeX engine could never be installed. Download now tries the GitHub tinytex-releases assets first and falls back through a couple of mirrors instead of giving up on the first failing source. After the base install, tlmgr now also pulls in most TeX Live collections (fonts, math/science, graphics, extra LaTeX, bibliography, European languages, etc.), so the bundled distribution ships with close to the full package set instead of just the ~30 base packages.
Compiling several .tex sources produced one output card per file, each with its own "Salva con nome..." dialog -- with a batch of documents that meant clicking through dozens of save dialogs one at a time. Outputs are now grouped by type (PDF / HTML): each group gets a single button that packs every file of that type into one ZIP and saves it in one shot. Single-file compiles keep the plain "Salva con nome..." save, and HTML files still get their individual preview button. Adds a small dependency-free ZIP writer (desktop/zip.js) since the project has no archiving library yet.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR enhances the application with ZIP export functionality for compiled outputs and improves the TeX distribution installation process with fallback URLs and additional package collections.
Key Changes
ZIP Export Feature
New
desktop/zip.jsmodule: Implements a minimal, dependency-free ZIP writer that packages multiple output files into a single downloadable archivedeflateRawSyncfor compressionUpdated output UI (
desktop/renderer/app.js):New IPC handler (
desktop/main.js):salva-ziphandler that creates ZIP archives and shows a save dialogTeX Distribution Installation Improvements
Fallback URL support (
desktop/latex.js):TINYTEX_URLfrom single URLs to arrays of candidate URLs per platformNew
scaricaConFallback()function:Extended package installation (
desktop/latex.js):COLLEZIONI_COMPLETEexport containing 17 TeX Live collections covering LaTeX, fonts, math/science, graphics, bibliography, and European languagesinstallaPacchettiBase()now installs both base packages and complete collectionsUI/CSS Updates
.output-file-liststyling for scrollable file lists in output cardsImplementation Details
https://claude.ai/code/session_01Wx82oS8KJJsa7jxJRx2xRi