From 2dbe2c73c599a29e86e4123b42e430828b1f01d9 Mon Sep 17 00:00:00 2001 From: NicolasGB Date: Tue, 7 Apr 2026 10:43:19 +0200 Subject: [PATCH] fix(terminal): make `cursor_render_delay` optional in the typesystem --- README.md | 4 ++-- lua/jj/ui/terminal.lua | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index eafabde..73242fe 100644 --- a/README.md +++ b/README.md @@ -425,10 +425,10 @@ The plugin also provides `:Jdiff`, `:Jvdiff`, and `:Jhdiff` commands for diffing -- If cursor column is being reset to 0 when refreshing commands, try increasing this value -- This delay allows the terminal emulator to complete rendering before restoring cursor position cursor_render_delay = 10, - + -- Configure terminal window window = { - type = "hsplit", -- Type of window the terminal is displayed in + type = "hsplit", -- Type of window the terminal is displayed in (hsplit/vsplit/floating/tab) split_size = 0.5, -- Size % of the split window, either height (hsplit) or width (vsplit) (between 0.1 and 1.0) floating_width = 0.99, -- Width % of the floating window (between 0.1 and 1.0) floating_height = 0.95, -- Height % of the floating window (between 0.1 and 1.0) diff --git a/lua/jj/ui/terminal.lua b/lua/jj/ui/terminal.lua index 11fbb42..1489014 100644 --- a/lua/jj/ui/terminal.lua +++ b/lua/jj/ui/terminal.lua @@ -3,7 +3,7 @@ local M = {} --- Terminal configuration --- @class jj.ui.terminal.opts ---- @field cursor_render_delay integer The delay in ms when cursor rerendering the terminal state (default: 10ms). If you're loosing the column of the cursor try adding more delay. I currently did not find a better way to do so due to async handling of the ouptut in the terminal +--- @field cursor_render_delay? integer The delay in ms when cursor rerendering the terminal state (default: 10ms). If you're loosing the column of the cursor try adding more delay. I currently did not find a better way to do so due to async handling of the ouptut in the terminal --- @field window? jj.terminal.window Options for the window used --- --- @class jj.terminal.window