diff --git a/catppuccin_latte.lua b/catppuccin_latte.lua new file mode 100644 index 0000000..f43d848 --- /dev/null +++ b/catppuccin_latte.lua @@ -0,0 +1,202 @@ +-- this line for types, by hovering and autocompletion (lsp required) +-- will help you understanding properties, fields, and what highlightings the color used for +---@type Base46Table +local M = {} +-- UI +M.base_30 = { + white = "#4c4f69", + black = "#dce0e8", -- usually your theme bg + darker_black = "#E9ECF1", -- 6% darker than black + black2 = "#ccd0da", -- 6% lighter than black + one_bg = "#C2C6D1", -- 10% lighter than black + one_bg2 = "#B1B5C3", -- 6% lighter than one_bg2 + one_bg3 = "#9ca0b0", -- 6% lighter than one_bg3 + grey = "#888FA5", -- 40% lighter than black (the % here depends so choose the perfect grey!) + grey_fg = "#6C748E", -- 10% lighter than grey + grey_fg2 = "#61697F", -- 5% lighter than grey + light_grey = "#5c5f77", + red = "#d20f39", + baby_pink = "#dc8a78", + pink = "#ea76cb", + line = "#8386a0", -- 15% lighter than black + green = "#40a02b", + vibrant_green = "#00AD83", + nord_blue = "#4f6d7a", + blue = "#1e66f5", + seablue = "#04a5e5", + yellow = "#df8e1d", -- 8% lighter than yellow + sun = "#eb961e", + purple = "#AA71F4", + dark_purple = "#8839ef", + teal = "#179299", + orange = "#fe640b", + cyan = "#209fb5", + statusline_bg = "#DCE0E8", + lightbg = "#CCD0DA", + pmenu_bg = "#A5B0C5", + folder_bg = "#1e66f5", + lavender = "#7287fd", + flamingo = "#dd7878", + maroon = "#e64553", +} + + +-- check https://github.com/chriskempson/base17/blob/master/styling.md for more info +M.base_16 = { + base00 = "#eff1f5", + base01 = "#e6e9ef", + base02 = "#ccd0da", + base03 = "#bcc0cc", + base04 = "#acb0be", + base05 = "#4c4f69", + base06 = "#dc8a78", + base07 = "#7287fd", + base08 = "#d20f39", + base09 = "#fe640b", + base0A = "#df8e1d", + base0B = "#40a02b", + base0C = "#179299", + base0D = "#1e66f5", + base0E = "#8839ef", + base0F = "#dd7878" +} + +-- OPTIONAL +-- overriding or adding highlights for this specific theme only +-- defaults/treesitter is the filename i.e integration there, + +local Style = { + Lifetimes = { + fg = M.base_16.base0D, + italic = true + }, + Macro = { + fg = M.base_30.sun, + }, + Comments = { + Todo = { + fg = M.base_30.seablue, + bg = "none", + italic = true, + }, + Warn = { + fg = M.base_30.sun, + bg = "none", + italic = true, + }, + Err = { + fg = M.base_30.maroon, + bg = "none", + italic = true, + }, + Note = { + fg = M.base_30.vibrant_green, + bg = "none", + italic = true, + } + }, + Keywords = { + General = { + fg = M.base_16.base0E, + }, + Import = { + fg = M.base_16.base0E, + bold = true, + }, + Function = { + italic = true, + }, + }, + Function = { + fg = M.base_16.base0D, + }, + Types = { + Interface = { + fg = M.base_30.vibrant_green, + }, + Builtin = { + fg = M.base_16.base0E, + }, + Defined = { + fg = M.base_30.sun, + italic = true, + }, + EnumMember = { + fg = M.base_16.base0C, + italic = true, + } + }, + GenericBracket = { + fg = M.base_30.seablue, + }, + Operators = { + fg = M.base_16.base0C, + }, +} + +M.polish_hl = { + treesitter = { + ["@attribute"] = Style.Lifetimes, + ["@attribute.builtin"] = Style.Lifetimes, + + ["@comment.error"] = Style.Comments.Err, + ["@comment.warning"] = Style.Comments.Warn, + ["@comment.todo"] = Style.Comments.Todo, + ["@comment.note"] = Style.Comments.Note, + ["@constant"] = { + fg = M.base_16.base09 + }, + ["@constant.builtin"] = Style.Types.EnumMember, + + ["@function.macro"] = Style.Macro, + ["@function.abstract"] = { + italic = true, + }, + + -- ["@local.definition.import"] = Style.Keywords.Import, + ["@local.definition.var"] = { + fg = M.base_30.maroon, + }, + + ["@keyword.import"] = Style.Keywords.Import, + ["@keyword"] = Style.Keywords.General, + ["@keyword.modifier"] = Style.Keywords.General, + ["@keyword.function"] = Style.Keywords.Function, + ["@keyword.repeat"] = Style.Keywords.General, + + ["@local.definition.import"] = Style.Macro, + + ["@module"] = Style.Macro, + + ["@operator"] = Style.Operators, + + ["@punctuation.bracket"] = { + fg = M.base_16.base08, + }, + ["@punctuation.special"] = Style.Macro, + ["@punctuation.generic.bracket"] = Style.GenericBracket, + ["@punctuation.delimiter"] = Style.Operators, + ["@property"] = Style.Types.EnumMember, + + ["@trait"] = Style.Types.Interface, + ["@type"] = Style.Types.Defined, + ["@type.builtin"] = Style.Types.Builtin, + + ["@variable.parameter"] = { + fg = M.base_30.maroon, + italic = true, + }, + ["@variable.builtin"] = Style.Keywords.General, + ["@variable.member"] = { + fg = M.base_16.base05, + } + }, +} + +-- set the theme type whether is dark or light +M.type = "light" -- "or light" + +-- this will be later used for users to override your theme table from chadrc +M = require("base46").override_theme(M, "Catppuccin latte") + +return M