feat: add more lsp hl group (#121)

This commit is contained in:
Michael Chris Lopez
2023-06-10 07:18:49 +08:00
committed by GitHub
parent 74d444054a
commit 0cb5aff21d
2 changed files with 39 additions and 5 deletions

View File

@@ -212,6 +212,7 @@ local function generate(p, opt)
sym "@keyword.function" { Statement },
sym "@keyword.operator" { Statement },
sym "@keyword.return" { Statement },
sym "@keyword.coroutine" { Statement },
sym "@label" { Statement },
sym "@method" { Function },
sym "@method.call" { Function },
@@ -268,14 +269,30 @@ local function generate(p, opt)
sym "@text.uri.markdown" { SpecialComment },
-- LSP Semantic Token Groups
sym "@lsp.type.boolean" { sym "@boolean" },
sym "@lsp.type.builtinType" { sym "@type.builtin" },
sym "@lsp.type.comment" { sym "@comment" },
sym "@lsp.type.enum" { sym "@type" },
sym "@lsp.type.enumMember" { sym "@constant" },
sym "@lsp.type.escapeSequence" { sym "@string.escape" },
sym "@lsp.type.formatSpecifier" { sym "@punctuation.special" },
sym "@lsp.type.keyword" { sym "@keyword" },
sym "@lsp.type.namespace" { sym "@namespace" },
sym "@lsp.type.number" { sym "@number" },
sym "@lsp.type.parameter" { sym "@parameter" },
sym "@lsp.type.property" { sym "@property" },
sym "@lsp.typemod.method.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.function.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.type.selfKeyword" { sym "@variable.builtin" },
sym "@lsp.type.string.rust" { sym "@string" },
sym "@lsp.type.typeAlias" { sym "@type.definition" },
sym "@lsp.type.unresolvedReference" { gui = "undercurl", sp = Error.fg },
sym "@lsp.type.variable" { sym "@variable" },
sym "@lsp.typemod.class.defaultLibrary" { sym "@type.builtin" },
sym "@lsp.typemod.enum.defaultLibrary" { sym "@type.builtin" },
sym "@lsp.typemod.enumMember.defaultLibrary" { sym "@constant.builtin" },
sym "@lsp.typemod.method.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.function.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.macro.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.keyword.async" { sym "@keyword.coroutine" },
sym "@lsp.typemod.operator.injected" { sym "@operator" },
sym "@lsp.typemod.string.injected" { sym "@string" },
sym "@lsp.typemod.variable.defaultLibrary" { sym "@variable.builtin" },

View File

@@ -212,6 +212,7 @@ local function generate(p, opt)
sym "@keyword.function" { Statement },
sym "@keyword.operator" { Statement },
sym "@keyword.return" { Statement },
sym "@keyword.coroutine" { Statement },
sym "@label" { Statement },
sym "@method" { Function },
sym "@method.call" { Function },
@@ -251,7 +252,7 @@ local function generate(p, opt)
sym "@text.underline" { Underlined },
sym "@text.uri" { Underlined },
sym "@text.warning" { WarningMsg },
sym "@todo" { Todo },
sym "@text.todo" { Todo },
sym "@type" { Type },
sym "@type.builtin" { Type },
sym "@type.definition" { Type },
@@ -268,14 +269,30 @@ local function generate(p, opt)
sym "@text.uri.markdown" { SpecialComment },
-- LSP Semantic Token Groups
sym "@lsp.type.boolean" { sym "@boolean" },
sym "@lsp.type.builtinType" { sym "@type.builtin" },
sym "@lsp.type.comment" { sym "@comment" },
sym "@lsp.type.enum" { sym "@type" },
sym "@lsp.type.enumMember" { sym "@constant" },
sym "@lsp.type.escapeSequence" { sym "@string.escape" },
sym "@lsp.type.formatSpecifier" { sym "@punctuation.special" },
sym "@lsp.type.keyword" { sym "@keyword" },
sym "@lsp.type.namespace" { sym "@namespace" },
sym "@lsp.type.number" { sym "@number" },
sym "@lsp.type.parameter" { sym "@parameter" },
sym "@lsp.type.property" { sym "@property" },
sym "@lsp.typemod.method.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.function.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.type.selfKeyword" { sym "@variable.builtin" },
sym "@lsp.type.string.rust" { sym "@string" },
sym "@lsp.type.typeAlias" { sym "@type.definition" },
sym "@lsp.type.unresolvedReference" { gui = "undercurl", sp = Error.fg },
sym "@lsp.type.variable" { sym "@variable" },
sym "@lsp.typemod.class.defaultLibrary" { sym "@type.builtin" },
sym "@lsp.typemod.enum.defaultLibrary" { sym "@type.builtin" },
sym "@lsp.typemod.enumMember.defaultLibrary" { sym "@constant.builtin" },
sym "@lsp.typemod.method.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.function.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.macro.defaultLibrary" { sym "@function.builtin" },
sym "@lsp.typemod.keyword.async" { sym "@keyword.coroutine" },
sym "@lsp.typemod.operator.injected" { sym "@operator" },
sym "@lsp.typemod.string.injected" { sym "@string" },
sym "@lsp.typemod.variable.defaultLibrary" { sym "@variable.builtin" },