feat: inline preview respects window side (left/right)#126
Draft
adriancmiranda wants to merge 1 commit into
Draft
feat: inline preview respects window side (left/right)#126adriancmiranda wants to merge 1 commit into
adriancmiranda wants to merge 1 commit into
Conversation
adriancmiranda
force-pushed
the
feat/inline-preview-side
branch
from
June 27, 2026 14:08
168be55 to
9803ae9
Compare
adriancmiranda
marked this pull request as draft
June 27, 2026 14:11
adriancmiranda
force-pushed
the
feat/inline-preview-side
branch
2 times, most recently
from
June 27, 2026 20:09
8b5ff9a to
f83bcd8
Compare
adriancmiranda
force-pushed
the
feat/inline-preview-side
branch
from
June 27, 2026 20:31
f83bcd8 to
b43dcc6
Compare
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.
Closes #121
Note
Float-based previewers (markdown, archive, cert, binary, font, key, sqlite) do not yet respect
window. Full support, including per-extension override andsize, is deferred to after #92 and thesizekey are implemented.Summary
windowconfig through the full call chain:init.lua->image.lua->preview_route.lua->inline.luapreview()now acceptsopts.window('left'/'right') and uses it to decide the split direction on first openwindowvalue -- preserves the Oil.nvim workflow where the preview stays in the same splitwindow = nilto the default config schema socfg.windowis always a valid fieldM.preview()without opts,cfg.windowis now consulted as fallbackvideo.lua) now respectswindowfor both thumbnail and animated paths; Oil passescfg.windowexplicitly when callingvideo.preview()model.luaunwrap guard:source_win.windowis only used as a window ID when it is actually a number; string position values ('left','right') are ignored, preventing E5108 regression introduced by this branchTest plan
window = 'left'in setup: first<leader>pin Oil opens image preview to the left of Oilwindow = 'left'in setup: first<leader>pin Oil opens video preview to the left of Oil<leader>ppresses reuse the same split, regardless of which file is previewed:GlimpsePreview leftand:GlimpsePreview rightstill work from any bufferwindowin config: behavior unchanged (preview opens to the right)