mirror of
https://github.com/obsqrbtz/clrsync.git
synced 2026-04-08 20:19:04 +03:00
init
This commit is contained in:
36
example_config/templates/formats-demo
Normal file
36
example_config/templates/formats-demo
Normal file
@@ -0,0 +1,36 @@
|
||||
# BASE COLORS (raw)
|
||||
color1.raw {term_red}
|
||||
|
||||
# HEX
|
||||
color1.hex {term_red.hex}
|
||||
color1.hex.stripped {term_red.hex_stripped}
|
||||
|
||||
color1.hexa {term_red.hexa}
|
||||
color1.hexa.stripped {term_red.hexa_stripped}
|
||||
|
||||
# RGB (0–255)
|
||||
color1.rgb {term_red.rgb}
|
||||
color1.r {term_red.r}
|
||||
color1.g {term_red.g}
|
||||
color1.b {term_red.b}
|
||||
|
||||
# RGBA (A = 0–1 normalized)
|
||||
color1.rgba {term_red.rgba}
|
||||
color1.a {term_red.a}
|
||||
|
||||
# HSL (normalized 0–1 for s,l, integers for h)
|
||||
color1.hsl {term_red.hsl}
|
||||
color1.h {term_red.h}
|
||||
color1.s {term_red.s}
|
||||
color1.l {term_red.l}
|
||||
|
||||
# HSLA
|
||||
color1.hsla {term_red.hsla}
|
||||
color1.hsla_a {term_red.hsla_a}
|
||||
|
||||
# Combined custom formats
|
||||
color1.r-g-b {term_red.r}-{term_red.g}-{term_red.b}
|
||||
color1.r-g-b-a {term_red.r}-{term_red.g}-{term_red.b}-{term_red.a}
|
||||
|
||||
color1.h-s-l {term_red.h}-{term_red.s}-{term_red.l}
|
||||
color1.h-s-l-a {term_red.h}-{term_red.s}-{term_red.l}-{term_red.hsla_a}
|
||||
32
example_config/templates/kitty.conf
Normal file
32
example_config/templates/kitty.conf
Normal file
@@ -0,0 +1,32 @@
|
||||
cursor {foreground}
|
||||
cursor_text_color {background}
|
||||
|
||||
foreground {foreground}
|
||||
background {background}
|
||||
selection_foreground {foreground_secondary}
|
||||
selection_background {surface}
|
||||
url_color {accent}
|
||||
|
||||
color8 {surface_variant}
|
||||
color0 {background}
|
||||
|
||||
color1 {term_red}
|
||||
color9 {term_red_bright}
|
||||
|
||||
color2 {term_green}
|
||||
color10 {term_green_bright}
|
||||
|
||||
color3 {term_yellow}
|
||||
color11 {term_yellow_bright}
|
||||
|
||||
color4 {term_blue}
|
||||
color12 {term_blue_bright}
|
||||
|
||||
color5 {term_magenta}
|
||||
color13 {term_magenta_bright}
|
||||
|
||||
color6 {term_cyan}
|
||||
color14 {term_cyan_bright}
|
||||
|
||||
color15 {term_white_bright}
|
||||
color7 {term_white}
|
||||
87
example_config/templates/nvim.lua
Normal file
87
example_config/templates/nvim.lua
Normal file
@@ -0,0 +1,87 @@
|
||||
vim.cmd("highlight clear")
|
||||
vim.cmd("syntax reset")
|
||||
vim.g.colors_name = "clrsync"
|
||||
|
||||
local palette = {
|
||||
-- TextEditor
|
||||
Default = "{text_main.hex}",
|
||||
Keyword = "{syntax_keyword.hex}",
|
||||
Number = "{text_warning.hex}",
|
||||
String = "{text_string.hex}",
|
||||
CharLiteral = "{text_string.hex}",
|
||||
Punctuation = "{text_main.hex}",
|
||||
Preprocessor = "{syntax_special_keyword.hex}",
|
||||
Identifier = "{text_main.hex}",
|
||||
KnownIdentifier = "{text_link.hex}",
|
||||
PreprocIdentifier = "{text_link.hex}",
|
||||
|
||||
Comment = "{text_comment.hex}",
|
||||
MultiLineComment = "{text_comment.hex}",
|
||||
|
||||
Background = "{editor_background.hex}",
|
||||
Cursor = "{cursor.hex}",
|
||||
|
||||
Selection = "{text_selected.hex}",
|
||||
ErrorMarker = "{syntax_error.hex}",
|
||||
Breakpoint = "{syntax_error.hex}",
|
||||
|
||||
LineNumber = "{text_line_number.hex}",
|
||||
CurrentLineFill = "{surface_variant.hex}",
|
||||
CurrentLineFillInactive = "{surface.hex}",
|
||||
|
||||
CurrentLineEdge = "{border_emphasized.hex}",
|
||||
}
|
||||
|
||||
-- Helper function to set highlights in Neovim
|
||||
local function set_hl(group, opts)
|
||||
vim.api.nvim_set_hl(0, group, opts)
|
||||
end
|
||||
|
||||
vim.o.winborder = "rounded"
|
||||
|
||||
-- Basic editor highlights using the mapped palette
|
||||
set_hl("Normal", { fg = palette.Default, bg = palette.Background })
|
||||
set_hl("CursorLine", { bg = palette.CurrentLineFill })
|
||||
set_hl("Visual", { bg = palette.Selection })
|
||||
set_hl("LineNr", { fg = palette.LineNumber })
|
||||
set_hl("CursorLineNr", { fg = palette.Keyword })
|
||||
|
||||
-- Syntax highlights
|
||||
set_hl("Comment", { fg = palette.Comment, italic = true })
|
||||
set_hl("Constant", { fg = palette.Number })
|
||||
set_hl("String", { fg = palette.String })
|
||||
set_hl("Character", { fg = palette.CharLiteral })
|
||||
set_hl("Identifier", { fg = palette.Identifier })
|
||||
set_hl("Function", { fg = palette.Keyword })
|
||||
set_hl("Statement", { fg = palette.Keyword })
|
||||
set_hl("PreProc", { fg = palette.Preprocessor })
|
||||
set_hl("Type", { fg = palette.Keyword })
|
||||
set_hl("Special", { fg = palette.PreprocIdentifier })
|
||||
set_hl("Underlined", { fg = palette.KnownIdentifier })
|
||||
set_hl("Error", { fg = palette.ErrorMarker, bg = palette.Background })
|
||||
set_hl("Todo", { fg = palette.Text, bg = palette.Keyword })
|
||||
|
||||
-- Floating windows
|
||||
set_hl("NormalFloat", { bg = palette.Background })
|
||||
set_hl("FloatBorder", { fg = palette.CurrentLineEdge, bg = palette.Background })
|
||||
|
||||
-- Completion menu
|
||||
set_hl("Pmenu", { bg = palette.Background })
|
||||
set_hl("PmenuSel", { bg = palette.Keyword, fg = palette.Background })
|
||||
|
||||
-- Git and diagnostic highlights
|
||||
set_hl("DiffAdd", { fg = palette.Success or palette.Default, bg = palette.Background })
|
||||
set_hl("DiffChange", { fg = palette.Keyword, bg = palette.Background })
|
||||
set_hl("DiffDelete", { fg = palette.ErrorMarker, bg = palette.Background })
|
||||
set_hl("DiagnosticError", { fg = palette.ErrorMarker })
|
||||
set_hl("DiagnosticWarn", { fg = palette.Number })
|
||||
set_hl("DiagnosticInfo", { fg = palette.Keyword })
|
||||
set_hl("DiagnosticHint", { fg = palette.PreprocIdentifier })
|
||||
|
||||
-- Treesitter links
|
||||
set_hl("@comment", { link = "Comment" })
|
||||
set_hl("@string", { fg = palette.String })
|
||||
set_hl("@function", { fg = palette.Keyword })
|
||||
set_hl("@variable", { fg = palette.Identifier })
|
||||
set_hl("@keyword", { fg = palette.Keyword })
|
||||
set_hl("@type", { fg = palette.Preprocessor })
|
||||
Reference in New Issue
Block a user