Current state
lua/config/plugins/specs/nvim-dap-ui.lua lines 44–45 contain a comment stating the panel height should have a minimum of 10 and a maximum of 25. The implementation is:
math.max(8, math.min(10, math.floor(total_ui_height * 0.15)))
This expression clamps the result to [8, 10] — the math.min(10, ...) caps the value at 10, and the math.max(8, ...) sets a floor of 8. The documented range [10, 25] is never achieved. On a large terminal the panel height is always 10 lines, not the up-to-25 the comment implies.
Ideal state
bottom_panel_height is computed with math.max(10, math.min(25, math.floor(total_ui_height * 0.15))), matching the comment.
- On terminals taller than approximately 67 rows the panel height grows proportionally up to 25 lines.
- The comment and the code agree so a reader can trust either without checking the other.
Out of scope
- Changing the
0.15 proportional factor.
- Changing the range values — only aligning the implementation with the existing comment.
Starting points
lua/config/plugins/specs/nvim-dap-ui.lua lines 44–45 — the comment and the math.max/math.min expression to correct
QA plan
- Open
nvim-dap-ui.lua and read lines 44–45 — expect math.max(10, math.min(25, math.floor(total_ui_height * 0.15))) and no comment/code discrepancy.
- Open Neovim in a terminal taller than ~70 rows, start a debug session, and observe the bottom panel height — expect it is greater than 10 lines.
- Open Neovim in a terminal shorter than ~67 rows, start a debug session, and observe the bottom panel — expect it is clamped at 10 lines.
- Run
stylua --check . — expect no formatting errors.
Done when
bottom_panel_height uses math.max(10, math.min(25, ...)) and the comment accurately describes the [10, 25] clamp range.
Current state
lua/config/plugins/specs/nvim-dap-ui.lualines 44–45 contain a comment stating the panel height should have a minimum of 10 and a maximum of 25. The implementation is:This expression clamps the result to [8, 10] — the
math.min(10, ...)caps the value at 10, and themath.max(8, ...)sets a floor of 8. The documented range [10, 25] is never achieved. On a large terminal the panel height is always 10 lines, not the up-to-25 the comment implies.Ideal state
bottom_panel_heightis computed withmath.max(10, math.min(25, math.floor(total_ui_height * 0.15))), matching the comment.Out of scope
0.15proportional factor.Starting points
lua/config/plugins/specs/nvim-dap-ui.lualines 44–45 — the comment and themath.max/math.minexpression to correctQA plan
nvim-dap-ui.luaand read lines 44–45 — expectmath.max(10, math.min(25, math.floor(total_ui_height * 0.15)))and no comment/code discrepancy.stylua --check .— expect no formatting errors.Done when
bottom_panel_heightusesmath.max(10, math.min(25, ...))and the comment accurately describes the [10, 25] clamp range.