nvim/lua/user/themes/nord/groups/lsp.lua
2023-10-28 00:00:00 +07:00

73 lines
3.7 KiB
Lua

local c = require('user.themes.nord.colors')
return {
-- LSP semantic tokens
['@lsp.type.boolean'] = { link = '@boolean' },
['@lsp.type.builtinType'] = { link = '@type.builtin' },
['@lsp.type.class'] = { link = '@type' },
['@lsp.type.comment'] = { link = '@comment' },
['@lsp.type.enum'] = { link = '@type' },
['@lsp.type.enumMember'] = { link = '@constant' },
['@lsp.type.escapeSequence'] = { link = '@string.escape' },
['@lsp.type.formatSpecifier'] = { link = '@punctuation.special' },
['@lsp.type.field'] = { link = '@field' },
['@lsp.type.function'] = { link = '@function' },
['@lsp.type.generic'] = { link = '@text' },
['@lsp.type.interface'] = { link = '@type' },
['@lsp.type.keyword'] = { link = '@keyword' },
['@lsp.type.macro'] = { link = '@function.macro' },
['@lsp.type.method'] = { link = '@method' },
['@lsp.type.namespace'] = { link = '@namespace' },
['@lsp.type.number'] = { link = '@number' },
['@lsp.type.operator'] = { link = '@operator' },
['@lsp.type.parameter'] = { link = '@parameter' },
['@lsp.type.property'] = { link = '@property' },
['@lsp.type.selfKeyword'] = { link = '@variable.builtin' },
['@lsp.type.typeAlias'] = { link = '@type.definition' },
['@lsp.type.unresolvedReference'] = { link = '@error' },
['@lsp.type.typeParameter'] = { link = '@parameter' },
['@lsp.type.struct'] = { link = 'Structure' },
['@lsp.type.variable'] = { link = '@variable' },
['@lsp.typemod.enum.defaultLibrary'] = { link = '@type.builtin' },
['@lsp.typemod.enumMember.defaultLibrary'] = { link = '@constant.builtin' },
['@lsp.typemod.function.defaultLibrary'] = { link = '@function.builtin' },
['@lsp.typemod.macro.defaultLibrary'] = { link = '@function.builtin' },
['@lsp.typemod.method.defaultLibrary'] = { link = '@function.builtin' },
['@lsp.typemod.operator.injected'] = { link = '@operator' },
['@lsp.typemod.string.injected'] = { link = '@string' },
['@lsp.typemod.type.defaultLibrary'] = { link = '@type.builtin' },
['@lsp.typemod.variable.defaultLibrary'] = { link = '@variable.builtin' },
['@lsp.typemod.variable.injected'] = { link = '@variable' },
['@lsp.typemod.variable.static'] = { link = '@constant' },
-- LSP
DiagnosticError = { fg = c.red },
DiagnosticWarn = { fg = c.yellow },
DiagnosticInfo = { fg = c.blue },
DiagnosticHint = { fg = c.cyan },
DiagnosticUnderlineError = { sp = c.red, underline = true },
DiagnosticUnderlineWarn = { sp = c.yellow, underline = true },
DiagnosticUnderlineInfo = { sp = c.blue, underline = true },
DiagnosticUnderlineHint = { sp = c.cyan, underline = true },
DiagnosticVirtualTextError = { fg = c.red, italic = true },
DiagnosticVirtualTextWarn = { fg = c.yellow, italic = true },
DiagnosticVirtualTextInfo = { fg = c.blue, italic = true },
DiagnosticVirtualTextHint = { fg = c.cyan, italic = true },
DiagnosticFloatingError = { link = 'DiagnosticError' },
DiagnosticFloatingWarn = { link = 'DiagnosticWarn' },
DiagnosticFloatingInfo = { link = 'DiagnosticInfo' },
DiagnosticFloatingHint = { link = 'DiagnosticHint' },
DiagnosticSignError = { link = 'DiagnosticError' },
DiagnosticSignWarn = { link = 'DiagnosticWarn' },
DiagnosticSignInfo = { link = 'DiagnosticInfo' },
DiagnosticSignHint = { link = 'DiagnosticHint' },
LspReferenceText = { bg = c.grey1 },
LspReferenceRead = { bg = c.grey1 },
LspReferenceWrite = { bg = c.grey1 },
LspCodeLens = { link = 'Comment' },
LspCodeLensSeparator = { fg = c.cyan, italic = true },
LspInlayHint = { link = 'Comment' },
LspSignatureActiveParameter = { bg = c.grey2 },
LspInfoBorder = { link = 'FloatBorder' },
}