feat: Support client-side rendering for PPTX and PPT files#1341
Open
spider-yamet wants to merge 18 commits intoeigent-ai:mainfrom
Open
feat: Support client-side rendering for PPTX and PPT files#1341spider-yamet wants to merge 18 commits intoeigent-ai:mainfrom
spider-yamet wants to merge 18 commits intoeigent-ai:mainfrom
Conversation
Contributor
Author
Contributor
Author
|
Please review my PR, @bytecii , @Wendong-Fan |
…thub.com/spider-yamet/eigent into feat/support-client-side-render-PPTX-PPT
Contributor
Author
|
@bytecii @Wendong-Fan could you please review this PR? |
Contributor
Author
|
@bytecii @Wendong-Fan could you please review this PR? |
Contributor
Author
|
@fengju0213 could you please review this pr? |
Collaborator
|
Thanks @spider-yamet for your contribution and your patience! Sorry for the delayed response — I'll do a detailed code review next and will follow up soon. |
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.


Related Issue
Closes #1339
Description
This PR adds client-side rendering for PPTX (and PPT) files in the Agent Folder, as requested in #1339.
What changed:
getFileAsDataUrl(path, type?)(inFileReader) so the renderer receives raw PPTX bytes as a data URL. Remote URLs are downloaded to a temp path first, then read and returned as a data URL.get-file-dataurlhandler andgetFileAsDataUrlonelectronAPI; preload andelectron.d.tsupdated.PptxViewercomponent (lazy-loaded) that decodes the data URL, parses the PPTX in the renderer with JSZip and the browser’s DOMParser, and renders slides with a filmstrip and prev/next controls.get-file-dataurlinstead ofopen-file; content area showsPptxViewerwhen content is a data URL. If IPC is unavailable (e.g. browser-only), a short message explains that PPTX preview is available in the desktop app.jszipfor browser-safe PPTX unzip in the renderer.Why: Preview was previously done in the main process (text-only HTML). Moving to client-side rendering matches the PDF pattern (raw bytes → renderer), supports remote files via the same path, and allows a proper slide-by-slide UI. Legacy
.pptis out of scope for this change.Testing Evidence (REQUIRED)
Contribution Guidelines Acknowledgement