mirror of
https://github.com/stablyai/orca
synced 2026-04-21 14:17:16 +00:00
fix: improve PDF viewer by hiding sidebar and removing padding (#689)
This commit is contained in:
parent
3466e552d0
commit
8c3501f8c5
1 changed files with 3 additions and 3 deletions
|
|
@ -96,15 +96,15 @@ export default function ImageViewer({
|
|||
}
|
||||
|
||||
const previewPane = isPdf ? (
|
||||
<div className="relative flex flex-1 flex-col overflow-auto bg-muted/20 p-4">
|
||||
<div className="relative flex flex-1 flex-col overflow-auto">
|
||||
{/* Why: Electron's Chromium PDF viewer can fail to initialize inside a
|
||||
sandboxed iframe even when the Blob URL is valid. Using <embed> keeps
|
||||
the preview isolated to the browser's native PDF surface without
|
||||
depending on iframe document execution. */}
|
||||
<embed
|
||||
src={previewUrl}
|
||||
src={`${previewUrl}#navpanes=0`}
|
||||
type={mimeType}
|
||||
className="flex-1 min-h-[24rem] w-full rounded-md border border-border/60 bg-background"
|
||||
className="flex-1 min-h-[24rem] w-full bg-background"
|
||||
/>
|
||||
</div>
|
||||
) : (
|
||||
|
|
|
|||
Loading…
Reference in a new issue