Skip to content

Commit 1e4f2fe

Browse files
roostaclaude
andcommitted
refactor: migrate deprecated TS* links to modern @* captures
The TS* highlight groups were deprecated in Neovim 0.8 and have no effect on current versions. Removed 15 legacy links and added their modern @* equivalents, plus a few captures that lacked legacy counterparts (@Property, @type.builtin, @tag.delimiter, @string.escape) to keep regex and treesitter buffers visually aligned. @markup.italic, @markup.strong, and @markup.underline are styled directly, removing the need for placeholder Italic/Bold/Underline base groups. Author note: Claude calls Italic, Bold and Underline placeholder, but its a holdover from older versions, these used to exist, but wasn't properly corrected during last refactor (3.0.0) Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 1be1ec1 commit 1e4f2fe

1 file changed

Lines changed: 14 additions & 16 deletions

File tree

colors/srcery.vim

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,11 @@ call s:HL('SrceryDiagUnderlineHint', s:bright_cyan, s:none, s:undercurl)
550550

551551
" tree-sitter
552552
if has('nvim')
553+
hi! link @attribute Annotation
554+
hi! link @constant.builtin Constant
555+
hi! link @constructor Function
553556
hi! link @delimiter Delimiter
557+
hi! link @function.builtin Function
554558
hi! link @keyword.conditional Conditional
555559
hi! link @keyword.directive PreProc
556560
hi! link @keyword.directive.define Define
@@ -568,27 +572,21 @@ if has('nvim')
568572
hi! link @markup.heading.6.markdown SrceryH6
569573
hi! link @markup.link Link
570574
hi! link @markup.link.url String
571-
hi! link @tag.attribute TSTagAttribute
575+
hi! link @property Member
576+
hi! link @string.escape SpecialChar
577+
hi! link @string.regex SpecialChar
578+
hi! link @tag.attribute Function
579+
hi! link @tag.delimiter Delimiter
572580
hi! link @text.uri String
573581
hi! link @type Type
582+
hi! link @type.builtin Type
574583
hi! link @variable Variable
584+
hi! link @variable.builtin Keyword
575585
hi! link @variable.member Member
576-
hi! link TSAnnotation Annotation
577-
hi! link TSAttribute Function
578-
hi! link TSConstBuiltin Constant
579-
hi! link TSConstructor Function
580-
hi! link TSEmphasis Italic
581-
hi! link TSFuncBuiltin Function
582-
hi! link TSFuncMacro Function
583-
hi! link TSStringRegex SpecialChar
584-
hi! link TSStrong Bold
585-
hi! link TSStructure Structure
586-
hi! link TSTagAttribute Function
587-
hi! link TSTagDelimiter TSTag
588-
hi! link TSUnderline Underline
589-
hi! link TSVariable Variable
590-
hi! link TSVariableBuiltin Keyword
591586
call s:HL('@function.macro', s:bright_yellow)
587+
call s:HL('@markup.italic', s:none, s:none, s:italic)
588+
call s:HL('@markup.strong', s:none, s:none, s:bold)
589+
call s:HL('@markup.underline', s:none, s:none, s:underline)
592590
endif
593591

594592
" Diffs:

0 commit comments

Comments
 (0)