diff --git a/LICENSE.md b/LICENSE.md index e2a98faf..be60013b 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -94,7 +94,7 @@ TEST EDIT #1: Testing if diffs appear consistently! TEST EDIT #2: Checking consistency of diff display! -CLEAN DIFF TEST: No more extra red lines on replacements! +VISUAL FIX TEST: Changed highlight group for replacements! SANITY CHECK: First edit after Neovim restart - will the diff appear? diff --git a/lua/nvim-claude/inline-diff.lua b/lua/nvim-claude/inline-diff.lua index b1b1b571..e2456460 100644 --- a/lua/nvim-claude/inline-diff.lua +++ b/lua/nvim-claude/inline-diff.lua @@ -180,15 +180,15 @@ function M.apply_diff_visualization(bufnr) -- Apply highlighting for replacements (show old text inline with new text) for j, repl in ipairs(replacements) do if repl.line >= 0 and repl.line < #buf_lines then - -- Highlight the line as changed + -- Highlight the line as an addition (since it shows the new text) vim.api.nvim_buf_set_extmark(bufnr, ns_id, repl.line, 0, { - line_hl_group = 'DiffChange', + line_hl_group = 'DiffAdd', id = 5000 + i * 100 + j }) -- Show the old text as virtual text at end of line vim.api.nvim_buf_set_extmark(bufnr, ns_id, repl.line, 0, { - virt_text = {{' ← was: ' .. repl.old_text, 'DiffDelete'}}, + virt_text = {{' ← was: ' .. repl.old_text, 'Comment'}}, virt_text_pos = 'eol', id = 6000 + i * 100 + j })