colors relative to base color

This commit is contained in:
2023-12-06 00:04:26 +01:00
parent b1ac562fd5
commit 4f7cde15ee
2 changed files with 63 additions and 46 deletions

View File

@@ -3,24 +3,25 @@ local hsl = lush.hsl -- We'll use hsl a lot so its nice to bind it separately
---@diagnostic disable: undefined-global
local theme = lush(function()
local red = hsl(0, 50, 75)
local orange = hsl(30, 50, 75)
local yellow = hsl(60, 50, 75)
local yellow_green = hsl(90, 50, 75)
local green = hsl(120, 50, 75)
local aquamarine = hsl(150, 50, 75)
local cyan = hsl(180, 50, 75)
local blue = hsl(210, 50, 75)
local lavender = hsl(240, 50, 75)
local purple = hsl(270, 50, 75)
local fuchsia = hsl(300, 50, 75)
local hot_pink = hsl(330, 50, 75)
local base = hsl(210, 40, 75)
local red = base.hue(0)
local orange = base.hue(30)
local yellow = base.hue(60)
local yellow_green = base.hue(90)
local green = base.hue(120)
local aquamarine = base.hue(150)
local cyan = base.hue(180)
local blue = base.hue(210)
local lavender = base.hue(240)
local purple = base.hue(270)
local fuchsia = base.hue(300)
local hot_pink = base.hue(330)
return {
-- See: h highlight-groups
Normal { bg = hsl(blue.h, 15, 20), fg = hsl(blue.h, 20, 75) },
Normal { bg = hsl(base.h, 15, 20), fg = hsl(base.h, 30, 75) },
CursorLine { bg = Normal.bg.li(10) },
Visual { bg = hsl(blue.h, 30, 30) },
Comment { fg = hsl(blue.h, 10, 60) },
Visual { bg = hsl(base.h, 30, 30) },
Comment { fg = hsl(base.h, 10, 60) },
CursorColumn { CursorLine },
LineNr { Comment, gui = "italic" },
CursorLineNr { fg = blue, bg = CursorLine.bg, gui = "italic" },
@@ -46,7 +47,7 @@ local theme = lush(function()
MoreMsg { fg = green, gui = "bold" },
Question { fg = green, gui = "bold" },
TelescopeSelection { CursorLine },
WhichKeyFloat { bg = hsl(blue.h, 15, 30) },
WhichKeyFloat { bg = hsl(base.h, 15, 30) },
DiagnosticError { fg = red },
DiagnosticWarn { fg = orange },
DiagnosticInfo { fg = cyan },