You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
IDE: PDF and image viewer tabs, on a generic custom-editor tab seam #256
area: ideThe Electron + Monaco IDE (apps/ide)stream: ide-powertfmAdds the issue to the TFM board automatically. Do not removeuser-storySub-issue of an epic ([Story] title prefix)
As a developer using the Code-XR IDE, I want PDF files and images in my folder to open in an editor tab, so that I can read papers, specs and diagrams without leaving the IDE.
Today the editor refuses binary files with "X is a binary file." (renderer/editor/editorGroup.ts).
Scope
Generic custom-editor seam in editorGroup.ts
openCustom(input): a tab whose content is a DOM element instead of a Monaco model.
It reuses the normal tab behaviour: preview tabs, close and middle-click, drag between groups, split, and session restore through registerCustomEditor(resolver).
The agent-first layout will open chat tabs through the same seam.
PDF viewer
pdf.js, bundled with its worker. No CSP relaxation: frames and objects stay forbidden.
Pages are rendered lazily on canvas, with the text layer so text can be selected and copied.
Zoom in and out, fit width, page number and page count, find in the document, and keyboard scrolling.
It reloads when the file changes on disk.
Image viewer
png, jpg, gif, webp, bmp, ico and avif.
svg is deliberately not included: it can carry script, so it stays a text file.
Zoom, fit, actual size, and the image dimensions and size in the toolbar.
Main process
Binary reads stay inside the folder, are size-capped, and do not depend on trust (they are read-only).
Acceptance criteria
Opening a .pdf from the explorer, Quick Open or search shows its pages in a tab; text is selectable and Ctrl+F finds it.
Opening an image shows it in a tab, with zoom and its size.
The tabs behave like file tabs: preview, keep, close, move to the other group, and restore after a restart.
A file changed on disk re-renders; a deleted one shows that it is gone.
The CSP is unchanged.
Unit tests cover the read limits and the seam; the smoke test passes on all three OSes.
area: ideThe Electron + Monaco IDE (apps/ide)stream: ide-powertfmAdds the issue to the TFM board automatically. Do not removeuser-storySub-issue of an epic ([Story] title prefix)
Activity
IDE: PDF and image viewer tabs on a generic custom-editor seam (#256)
Merge pull request #280 from Code-XR-Project/claude/project-thread-kr…