add plugin highlight groups to colourscheme
This commit is contained in:
parent
e538a0b150
commit
e08ca2e42c
|
|
@ -412,14 +412,24 @@ Source of truth for the step-by-step rebuild. Keep this concise and up to date.
|
|||
- [ ] Test with existing custom queries (after/queries/css/highlights.scm, after/queries/html/highlights.scm)
|
||||
|
||||
## Phase 11.8 — Plugin highlight groups
|
||||
- [ ] Create `lua/paper-tonic-modern/groups/lsp.lua`
|
||||
- [ ] Define LSP diagnostics: DiagnosticError, DiagnosticWarn, DiagnosticHint, DiagnosticInfo
|
||||
- [ ] Define LSP UI: LspReferenceText, LspReferenceRead, LspReferenceWrite
|
||||
- [ ] Create `lua/paper-tonic-modern/groups/plugins.lua`
|
||||
- [ ] Add Telescope highlights (TelescopeNormal, TelescopeBorder, TelescopeSelection)
|
||||
- [ ] Add Gitsigns highlights (GitSignsAdd, GitSignsChange, GitSignsDelete)
|
||||
- [ ] Add nvim-cmp highlights (CmpItemKind*, CmpItemMenu, etc.)
|
||||
- [ ] Add Oil.nvim highlights if needed
|
||||
- [x] Create `lua/paper-tonic-modern/groups/lsp.lua`
|
||||
- [x] Define LSP diagnostics: DiagnosticError, DiagnosticWarn, DiagnosticHint, DiagnosticInfo
|
||||
- [x] Define LSP UI: LspReferenceText, LspReferenceRead, LspReferenceWrite
|
||||
- [x] Create `lua/paper-tonic-modern/groups/plugins.lua`
|
||||
- [x] Add Telescope highlights (TelescopeNormal, TelescopeBorder, TelescopeSelection)
|
||||
- [x] Add Gitsigns highlights (GitSignsAdd, GitSignsChange, GitSignsDelete)
|
||||
- [x] Add nvim-cmp highlights (CmpItemKind*, CmpItemMenu, etc.)
|
||||
- [x] Add Oil.nvim highlights if needed
|
||||
|
||||
**Notes**:
|
||||
- LSP diagnostics use red (error), orange (warn), blue (info), green (hint)
|
||||
- LSP references use cyan backgrounds with varying intensity (text/read/write)
|
||||
- LSP semantic tokens link to TreeSitter groups for consistency
|
||||
- Telescope uses neutral colors with primary accent for matching and selection
|
||||
- Gitsigns uses status colors: green (add), blue (change), red (delete)
|
||||
- nvim-cmp uses primary tones for kinds, bold for matching text
|
||||
- Oil.nvim uses bold for directories, status colors for permissions and operations
|
||||
- indent-blankline and ufo use subtle grays for non-intrusive UI
|
||||
|
||||
## Phase 11.9 — Update plugin configuration
|
||||
- [ ] Update `lua/plugins/colorscheme.lua` to use paper-tonic-modern
|
||||
|
|
|
|||
12
README.md
12
README.md
|
|
@ -143,6 +143,18 @@ Record every decision here with a short rationale. Append new entries; do not re
|
|||
- **Priority fix**: Added `(#set! priority 200)` to all custom captures to override built-in captures (@string priority 99, @constant default priority)
|
||||
- **Technical note**: Custom queries require `;extends` directive and higher priority than built-in captures to work correctly
|
||||
- **Pseudo-class design**: Uses bold brownish-red (primary_strong) instead of green to distinguish behavioral modifiers (:hover, :focus) from structural selectors (.class, #id)
|
||||
- 2025-12-11: Colorscheme Phase 11.8:
|
||||
- **LSP highlights**: Comprehensive diagnostic and UI highlights
|
||||
- **LSP diagnostics**: Error (red #d70000), Warn (orange #d75f00), Info (blue #8989af), Hint (green #89af89)
|
||||
- **LSP diagnostic UI**: Underlines (undercurl for errors/warnings), signs, floating windows, virtual text with tinted backgrounds
|
||||
- **LSP references**: Cyan background gradients - Text (#e0eaff subtle), Read (#d4f0ff medium), Write (#a3e0ff strong)
|
||||
- **LSP semantic tokens**: Fallback groups linking to TreeSitter equivalents for consistency
|
||||
- **Telescope highlights**: Neutral base with primary accent for matching, selection, and titles
|
||||
- **Gitsigns highlights**: Status colors - Add (green), Change (blue), Delete (red); inline diff backgrounds
|
||||
- **nvim-cmp highlights**: Primary tones for item kinds, bold for match highlighting, italic for menu
|
||||
- **Oil.nvim highlights**: Bold directories, status colors for permissions (read=green, write=orange, execute=blue), operation colors
|
||||
- **indent-blankline**: Subtle grays for guides and scope
|
||||
- **nvim-ufo**: Subtle backgrounds for folds with preview support
|
||||
|
||||
## Project-Local Configuration (design)
|
||||
|
||||
|
|
|
|||
|
|
@ -1,12 +1,80 @@
|
|||
-- Paper Tonic Modern - LSP Highlight Groups
|
||||
-- LSP diagnostics and UI elements
|
||||
-- LSP diagnostics, references, and UI elements
|
||||
|
||||
local colors = require('paper-tonic-modern.colors')
|
||||
local c = require('paper-tonic-modern.colors')
|
||||
|
||||
return {
|
||||
-- LSP groups (to be implemented in Phase 11.8)
|
||||
DiagnosticError = { fg = colors.alert_strong },
|
||||
DiagnosticWarn = { fg = colors.alert },
|
||||
DiagnosticInfo = { fg = colors.question },
|
||||
DiagnosticHint = { fg = colors.fg },
|
||||
-- ============================================================================
|
||||
-- LSP Diagnostics
|
||||
-- ============================================================================
|
||||
|
||||
-- Error diagnostics (red)
|
||||
DiagnosticError = { fg = c.alert_strong }, -- Bright red #d70000
|
||||
DiagnosticUnderlineError = { sp = c.alert_strong, undercurl = true },
|
||||
DiagnosticSignError = { fg = c.alert_strong, bg = c.bg },
|
||||
DiagnosticFloatingError = { fg = c.alert_strong },
|
||||
DiagnosticVirtualTextError = { fg = c.alert_strong, bg = c.bg_error_weak },
|
||||
|
||||
-- Warning diagnostics (orange)
|
||||
DiagnosticWarn = { fg = c.alert }, -- Orange-red #d75f00
|
||||
DiagnosticUnderlineWarn = { sp = c.alert, undercurl = true },
|
||||
DiagnosticSignWarn = { fg = c.alert, bg = c.bg },
|
||||
DiagnosticFloatingWarn = { fg = c.alert },
|
||||
DiagnosticVirtualTextWarn = { fg = c.alert, bg = c.bg_fail },
|
||||
|
||||
-- Info diagnostics (blue)
|
||||
DiagnosticInfo = { fg = c.modified }, -- Blue #8989af
|
||||
DiagnosticUnderlineInfo = { sp = c.modified, underline = true },
|
||||
DiagnosticSignInfo = { fg = c.modified, bg = c.bg },
|
||||
DiagnosticFloatingInfo = { fg = c.modified },
|
||||
DiagnosticVirtualTextInfo = { fg = c.modified, bg = c.bg_modified },
|
||||
|
||||
-- Hint diagnostics (green)
|
||||
DiagnosticHint = { fg = c.success }, -- Green #89af89
|
||||
DiagnosticUnderlineHint = { sp = c.success, underline = true },
|
||||
DiagnosticSignHint = { fg = c.success, bg = c.bg },
|
||||
DiagnosticFloatingHint = { fg = c.success },
|
||||
DiagnosticVirtualTextHint = { fg = c.success, bg = c.bg_success },
|
||||
|
||||
-- ============================================================================
|
||||
-- LSP References (document highlight)
|
||||
-- ============================================================================
|
||||
|
||||
-- Text under cursor (current symbol)
|
||||
LspReferenceText = { bg = c.bg_hl_special_weak }, -- Subtle cyan #e0eaff
|
||||
|
||||
-- Read references (where symbol is read)
|
||||
LspReferenceRead = { bg = c.bg_hl_special }, -- Cyan #d4f0ff
|
||||
|
||||
-- Write references (where symbol is written/modified)
|
||||
LspReferenceWrite = { bg = c.bg_hl_special_strong }, -- Strong cyan #a3e0ff
|
||||
|
||||
-- ============================================================================
|
||||
-- LSP Signature Help
|
||||
-- ============================================================================
|
||||
|
||||
LspSignatureActiveParameter = { fg = c.primary_strong, bold = true },
|
||||
|
||||
-- ============================================================================
|
||||
-- LSP Semantic Tokens (fallback groups)
|
||||
-- ============================================================================
|
||||
|
||||
-- These are fallback groups for LSP semantic tokens
|
||||
-- TreeSitter groups take precedence when both are available
|
||||
['@lsp.type.class'] = '@type',
|
||||
['@lsp.type.decorator'] = '@function',
|
||||
['@lsp.type.enum'] = '@type',
|
||||
['@lsp.type.enumMember'] = '@constant',
|
||||
['@lsp.type.function'] = '@function',
|
||||
['@lsp.type.interface'] = '@type',
|
||||
['@lsp.type.macro'] = '@macro',
|
||||
['@lsp.type.method'] = '@function.method',
|
||||
['@lsp.type.namespace'] = '@module',
|
||||
['@lsp.type.parameter'] = '@variable.parameter',
|
||||
['@lsp.type.property'] = '@property',
|
||||
['@lsp.type.struct'] = '@type',
|
||||
['@lsp.type.type'] = '@type',
|
||||
['@lsp.type.typeParameter'] = '@type',
|
||||
['@lsp.type.variable'] = '@variable',
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,165 @@
|
|||
-- Paper Tonic Modern - Plugin Highlight Groups
|
||||
-- Highlights for various plugins (Telescope, Gitsigns, cmp, etc.)
|
||||
-- Highlights for various plugins (Telescope, Gitsigns, cmp, Oil, etc.)
|
||||
|
||||
local colors = require('paper-tonic-modern.colors')
|
||||
local c = require('paper-tonic-modern.colors')
|
||||
|
||||
return {
|
||||
-- Plugin groups (to be implemented in Phase 11.8)
|
||||
-- Telescope, Gitsigns, nvim-cmp, Oil.nvim, etc.
|
||||
-- ============================================================================
|
||||
-- Telescope
|
||||
-- ============================================================================
|
||||
|
||||
TelescopeNormal = { fg = c.fg, bg = c.bg },
|
||||
TelescopeBorder = { fg = c.fg_weak, bg = c.bg },
|
||||
TelescopeTitle = { fg = c.primary_strong, bold = true },
|
||||
|
||||
-- Selection
|
||||
TelescopeSelection = { fg = c.fg_stronger, bg = c.bg_hl },
|
||||
TelescopeSelectionCaret = { fg = c.primary, bg = c.bg_hl },
|
||||
|
||||
-- Matching
|
||||
TelescopeMatching = { fg = c.primary, bold = true },
|
||||
|
||||
-- Prompts
|
||||
TelescopePromptNormal = { fg = c.fg, bg = c.bg_ui },
|
||||
TelescopePromptBorder = { fg = c.fg_weak, bg = c.bg_ui },
|
||||
TelescopePromptTitle = { fg = c.primary_strong, bold = true },
|
||||
TelescopePromptPrefix = { fg = c.primary },
|
||||
TelescopePromptCounter = { fg = c.fg_weak },
|
||||
|
||||
-- Results
|
||||
TelescopeResultsNormal = { fg = c.fg, bg = c.bg },
|
||||
TelescopeResultsBorder = { fg = c.fg_weak, bg = c.bg },
|
||||
TelescopeResultsTitle = { fg = c.fg_strong, bold = true },
|
||||
|
||||
-- Preview
|
||||
TelescopePreviewNormal = { fg = c.fg, bg = c.bg },
|
||||
TelescopePreviewBorder = { fg = c.fg_weak, bg = c.bg },
|
||||
TelescopePreviewTitle = { fg = c.fg_strong, bold = true },
|
||||
|
||||
-- ============================================================================
|
||||
-- Gitsigns
|
||||
-- ============================================================================
|
||||
|
||||
-- Signs in the gutter
|
||||
GitSignsAdd = { fg = c.success, bg = c.bg }, -- Green
|
||||
GitSignsChange = { fg = c.modified, bg = c.bg }, -- Blue
|
||||
GitSignsDelete = { fg = c.fail, bg = c.bg }, -- Red
|
||||
|
||||
-- Line highlights (when enabled)
|
||||
GitSignsAddLn = { bg = c.bg_success },
|
||||
GitSignsChangeLn = { bg = c.bg_modified },
|
||||
GitSignsDeleteLn = { bg = c.bg_fail },
|
||||
|
||||
-- Virtual text (inline blame, etc.)
|
||||
GitSignsCurrentLineBlame = { fg = c.fg_weak, italic = true },
|
||||
|
||||
-- Diff highlights
|
||||
GitSignsAddInline = { bg = c.bg_hl_special_alt },
|
||||
GitSignsChangeInline = { bg = c.bg_hl_special },
|
||||
GitSignsDeleteInline = { bg = c.bg_error_weak },
|
||||
|
||||
-- ============================================================================
|
||||
-- nvim-cmp (completion menu)
|
||||
-- ============================================================================
|
||||
|
||||
-- Menu
|
||||
CmpItemMenu = { fg = c.fg_weak, italic = true },
|
||||
CmpItemAbbrMatch = { fg = c.primary, bold = true },
|
||||
CmpItemAbbrMatchFuzzy = { fg = c.primary_weak },
|
||||
CmpItemAbbrDeprecated = { fg = c.fg_weak, strikethrough = true },
|
||||
|
||||
-- Kind icons/labels
|
||||
CmpItemKindDefault = { fg = c.fg },
|
||||
CmpItemKindVariable = { fg = c.fg },
|
||||
CmpItemKindFunction = { fg = c.primary_weak },
|
||||
CmpItemKindMethod = { fg = c.primary_weak },
|
||||
CmpItemKindConstructor = { fg = c.primary },
|
||||
CmpItemKindClass = { fg = c.primary_strong },
|
||||
CmpItemKindInterface = { fg = c.primary_strong },
|
||||
CmpItemKindStruct = { fg = c.primary_strong },
|
||||
CmpItemKindProperty = { fg = c.fg_strong },
|
||||
CmpItemKindField = { fg = c.fg_strong },
|
||||
CmpItemKindEnum = { fg = c.primary },
|
||||
CmpItemKindEnumMember = { fg = c.fg_strong },
|
||||
CmpItemKindModule = { fg = c.primary },
|
||||
CmpItemKindKeyword = { fg = c.primary_weak },
|
||||
CmpItemKindSnippet = { fg = c.modified },
|
||||
CmpItemKindText = { fg = c.fg },
|
||||
CmpItemKindFile = { fg = c.fg },
|
||||
CmpItemKindFolder = { fg = c.fg_strong },
|
||||
CmpItemKindColor = { fg = c.alert },
|
||||
CmpItemKindUnit = { fg = c.fg_weak },
|
||||
CmpItemKindValue = { fg = c.fg_strong },
|
||||
CmpItemKindConstant = { fg = c.fg_strong },
|
||||
CmpItemKindReference = { fg = c.modified },
|
||||
CmpItemKindOperator = { fg = c.fg },
|
||||
CmpItemKindTypeParameter = { fg = c.primary },
|
||||
|
||||
-- ============================================================================
|
||||
-- Oil.nvim (file explorer)
|
||||
-- ============================================================================
|
||||
|
||||
OilDir = { fg = c.fg_strong, bold = true },
|
||||
OilDirIcon = { fg = c.fg_strong },
|
||||
OilLink = { fg = c.modified },
|
||||
OilLinkTarget = { fg = c.fg_weak },
|
||||
OilFile = { fg = c.fg },
|
||||
OilFileIcon = { fg = c.fg },
|
||||
OilSize = { fg = c.fg_weak },
|
||||
OilPermissionNone = { fg = c.fg_weaker },
|
||||
OilPermissionRead = { fg = c.success },
|
||||
OilPermissionWrite = { fg = c.alert },
|
||||
OilPermissionExecute = { fg = c.modified },
|
||||
OilCopy = { fg = c.success, bold = true },
|
||||
OilMove = { fg = c.modified, bold = true },
|
||||
OilCreate = { fg = c.success, bold = true },
|
||||
OilDelete = { fg = c.fail, bold = true },
|
||||
OilChange = { fg = c.modified, bold = true },
|
||||
OilRestore = { fg = c.success },
|
||||
OilPurge = { fg = c.alert_strong, bold = true },
|
||||
OilTrash = { fg = c.fail },
|
||||
OilTrashSourcePath = { fg = c.fg_weak, italic = true },
|
||||
|
||||
-- ============================================================================
|
||||
-- Comment.nvim
|
||||
-- ============================================================================
|
||||
|
||||
-- Uses default Comment group
|
||||
|
||||
-- ============================================================================
|
||||
-- nvim-surround
|
||||
-- ============================================================================
|
||||
|
||||
-- Uses default highlighting
|
||||
|
||||
-- ============================================================================
|
||||
-- nvim-autopairs
|
||||
-- ============================================================================
|
||||
|
||||
-- Uses default highlighting
|
||||
|
||||
-- ============================================================================
|
||||
-- indent-blankline.nvim
|
||||
-- ============================================================================
|
||||
|
||||
IblIndent = { fg = c.fg_weaker },
|
||||
IblScope = { fg = c.fg_weak },
|
||||
|
||||
-- ============================================================================
|
||||
-- nvim-ufo (folding)
|
||||
-- ============================================================================
|
||||
|
||||
UfoFoldedBg = { bg = c.bg_hl_weak },
|
||||
UfoFoldedFg = { fg = c.fg_weak },
|
||||
UfoCursorFoldedLine = { bg = c.bg_hl, fg = c.fg },
|
||||
UfoPreviewBorder = { fg = c.fg_weak },
|
||||
UfoPreviewNormal = { bg = c.bg_ui },
|
||||
UfoPreviewCursorLine = { bg = c.bg_hl },
|
||||
|
||||
-- ============================================================================
|
||||
-- undotree
|
||||
-- ============================================================================
|
||||
|
||||
-- Uses default highlighting (mainly reuses diff colors)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue