Draft product.md for warpdotdev/warp#9729. To be committed under specs/GH9729/product.md once the issue receives ready-to-spec.
Clicking an image in Warp's File Tree opens it as a text file in the Code Editor. There is no way to view image assets without leaving Warp.
- Native image preview in the existing Code Editor tab system.
- Lightweight in-directory navigation between images, keyboard-first.
- Reuse the existing image-decode and EXIF pipeline used for Agent context attachments.
- Image editing, annotation, drawing.
- RAW formats (CR2, NEF, ARW, DNG): out of scope for v1; Reveal in Finder/Files is the escape hatch.
- PDFs: separate feature.
- Image diffing across git revisions: follow-up.
- Slideshow / full-screen presentation mode.
- Remote URL preview; local files only.
- Terminal-grid inline images: tracked in #1693 and #5286, unrelated surface.
- Clicking a file with extension
.png,.jpg,.jpeg,.gif,.webp,.svg,.heic,.heif,.bmp,.tiff,.tif,.avif, or.icoin the File Tree opens an Image Preview tab, not a text editor tab. - Magic-byte sniffing overrides the extension when they disagree. A
.pngfile that is actually JPEG opens correctly. A.pngfile that is text opens as text with a non-blocking warning. - The Image Preview tab participates in the existing tab system: draggable, splittable, closeable, restorable across sessions, identical keyboard shortcuts for tab navigation.
- The main view fits the image to the pane on open, preserving aspect ratio, never upscaling beyond 100% by default.
Cmd+=zooms in by 25 percent steps up to 1600 percent.Cmd+-zooms out by 25 percent steps down to a level where the image fits the pane.Cmd+0returns to Fit. The keybindings appear in Settings, Keyboard shortcuts and are rebindable.- Trackpad pinch zooms around the cursor. Trackpad two-finger scroll pans when zoomed and is a no-op at Fit. Click-and-drag pans when zoomed.
- The status footer shows filename, pixel dimensions, file size in human-readable units, and format string. It is always visible.
- Animated GIF, animated WebP, and animated AVIF auto-play on open and loop. A play/pause control is visible and toggleable. The pause state persists when navigating to the next image and back.
- SVG renders via vector rasterization at the current zoom level. The rendering remains visually sharp at every zoom step (no fixed-resolution bitmap).
- EXIF orientation is honored for both the main view and thumbnails. An image with EXIF rotation 6 displays portrait without manual rotation.
- Embedded ICC color profiles are respected on macOS via ColorSync. On Linux and Windows the v1 behavior is documented as best-effort sRGB fallback.
- The thumbnail strip lists every supported image file in the same directory as the open image, sorted by case-insensitive natural filename order (so
img2.pngprecedesimg10.png). - The current image's thumbnail is visibly selected and the strip auto-scrolls to keep it in view.
- Pressing Left or Right arrow with the preview pane focused navigates to the previous or next image in the strip. Home and End jump to first and last. Navigation does not wrap; it stops at ends.
- Clicking a thumbnail replaces the current preview in the same tab.
Cmd+clickon a thumbnail opens it in a new tab. - Thumbnails are decoded on a background thread pool. The strip never blocks the UI; it shows skeleton placeholders until decode completes.
- Thumbnails are cached on disk keyed by (canonical path, mtime, size, target dimension). Cache invalidates on mtime change.
- The thumbnail strip is virtualized: directories with more than 500 images render only the visible thumbnails plus a small overscan; memory does not grow linearly with directory size.
- A corrupt or unreadable image opens with a non-blocking error state showing filename, error reason, and a Reveal in Finder/Files action. The editor pane does not crash and other tabs are unaffected.
- The right-click context menu on the preview surface offers, in order: Copy Image, Copy file path (relative), Copy file path (absolute), Reveal in Finder/Files, Attach as Agent context.
- Dragging from the preview surface into an Agent prompt input attaches the image as context using the existing image-attach pipeline; no new wire format.
- Closing all Image Preview tabs reclaims any decoded full-size image memory. The idle thumbnail cache obeys a configurable size cap (default 256 MB) under Settings, Editor, Image preview.
- Nothing about this feature changes terminal escape-sequence handling. The terminal grid path is unaffected.
- Should the thumbnail strip include subdirectory traversal (depth 1, opt-in)? v1 default: no.
- Should
.psdand.xcfget a "supported but flat-composite only" tier? v1 default: no. - Should we offer a checkerboard backdrop toggle for transparent images? Strong yes; revisit during design review.
- Should single-clicking a thumbnail focus-but-not-load (preserving the current preview until Enter or double-click), or load immediately? v1 proposal: load immediately.