diff --git a/doc/diffs.nvim.txt b/doc/diffs.nvim.txt index 76e5ea3..dacbfa6 100644 --- a/doc/diffs.nvim.txt +++ b/doc/diffs.nvim.txt @@ -62,12 +62,12 @@ Configuration is done via `vim.g.diffs`. Set this before the plugin loads: }, vim = { enabled = false, - max_lines = 200, + max_lines = 500, }, intra = { enabled = true, algorithm = 'auto', - max_lines = 200, + max_lines = 500, }, }, fugitive = { @@ -165,7 +165,7 @@ Configuration is done via `vim.g.diffs`. Set this before the plugin loads: `vim.diff()`. `'vscode'`: require libvscodediff (falls back to native if not available). - {max_lines} (integer, default: 200) + {max_lines} (integer, default: 500) Skip character-level highlighting for hunks larger than this many lines. @@ -382,15 +382,16 @@ Fugitive unified diff highlights: ~ *DiffsAddText* DiffsAddText Character-level background for changed characters - within `+` lines. Derived by blending `DiffAdd` - background with `Normal` at 70% alpha (brighter - than line-level `DiffsAdd`). Only sets `bg`, so - treesitter foreground colors show through. + within `+` lines. Derived by blending `diffAdded` + foreground with `Normal` background at 40% alpha. + Uses the same base color as `DiffsAddNr` foreground, + making changed characters clearly visible. Only sets + `bg`, so treesitter foreground colors show through. *DiffsDeleteText* DiffsDeleteText Character-level background for changed characters - within `-` lines. Derived by blending `DiffDelete` - background with `Normal` at 70% alpha. + within `-` lines. Derived by blending `diffRemoved` + foreground with `Normal` background at 40% alpha. Diff mode window highlights: ~ These are used for |winhighlight| remapping in `&diff` windows. diff --git a/lua/diffs/init.lua b/lua/diffs/init.lua index ea33a32..d2097b1 100644 --- a/lua/diffs/init.lua +++ b/lua/diffs/init.lua @@ -91,7 +91,7 @@ local default_config = { intra = { enabled = true, algorithm = 'auto', - max_lines = 200, + max_lines = 500, }, }, fugitive = { @@ -183,8 +183,8 @@ local function compute_highlight_groups() local blended_add = blend_color(add_bg, bg, 0.4) local blended_del = blend_color(del_bg, bg, 0.4) - local blended_add_text = blend_color(add_bg, bg, 0.7) - local blended_del_text = blend_color(del_bg, bg, 0.7) + local blended_add_text = blend_color(add_fg, bg, 0.4) + local blended_del_text = blend_color(del_fg, bg, 0.4) vim.api.nvim_set_hl(0, 'DiffsAdd', { default = true, bg = blended_add }) vim.api.nvim_set_hl(0, 'DiffsDelete', { default = true, bg = blended_del })