nvimdev / nvimdev/lspsaga.nvim

Floating window with diagnostic details don't follow scroll nor z motions

Open
#1,421 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Lua
Stars
3.8k
Forks
308
PR merge metrics
No merged PRs in 30d

Description

Describe the bug

When I run zz (or <C-y>/<C-e>) after require("lspsaga.diagnostic"):goto_X, the floating window with diagnostic details remains at the same position.

Steps to reproduce

Have an error in a buffer outside the viewport.

require("lspsaga.diagnostic"):goto_prev({ severity = vim.diagnostic.severity.ERROR })
vim.cmd("normal! zz")

Floating window will remain in its original position.

Expected behavior

Floating window moves with the screen.

P.S. Or at least having an option to center the diagnostic origin.

Neovim version (nvim -v)

NVIM v0.10.0-dev-2138+gfa9a85ae4 Build type: Release LuaJIT 2.1.1703358377

lspsaga commit

a4d4428

Terminal name/version

Alacritty 0.12.2 (1)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the diagnostic entry points shown in the report, such as require("lspsaga.diagnostic"):goto_prev and goto_X, and reproduce the behavior with zz or Ctrl-y/Ctrl-e. Trace how the diagnostic details floating window is positioned, then verify that it follows screen scrolling and z motions while navigating diagnostics.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.