Skip to content

Commit

Permalink
fix: update StyleType annotation
Browse files Browse the repository at this point in the history
  • Loading branch information
shellRaining committed Oct 1, 2024
1 parent 8169b0a commit c68923a
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion lua/hlchunk/mods/base_mod/base_conf.lua
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
local class = require("hlchunk.utils.class")
local ft = require("hlchunk.utils.filetype")

---@alias HlChunk.StyleType string | table<string, string> | table<string, table<string, string>>
---@alias HexColor string # a rgb color string, e.g. "#ff0000"
---@alias StyleEntry { bg: HexColor, fg: HexColor }
---@alias StyleTypeBase
---| HexColor # a single color
---| HexColor[] # a rgb color string array, e.g. {"#ff0000", "#00ff00"}
---| vim.api.keyset.highlight[] # a style entry array, e.g. {{bg = "#ff0000", fg = "#00ff00"}, {bg = "#00ff00", fg = "#ff0000"}}
---@alias StyleTypeFunction fun(): StyleTypeBase
---@alias HlChunk.StyleType StyleTypeBase | StyleTypeFunction

---@class HlChunk.UserBaseConf
---@field enable? boolean
Expand Down

0 comments on commit c68923a

Please sign in to comment.