Skip to content

Commit

Permalink
Update vendor
Browse files Browse the repository at this point in the history
  • Loading branch information
notomo committed Jan 9, 2024
1 parent e31b5c4 commit 482d558
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lua/piemenu/vendor/misclib/highlight.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
local M = {}

--- Defines a default highlight group.
--- @param hl_group string: highlight group name
--- @param attributes table: |nvim_set_hl| val parameter
--- @return string # hl_group
function M.define(hl_group, attributes)
local new_attributes = { default = true }
for key, value in pairs(attributes) do
Expand All @@ -11,6 +15,10 @@ function M.define(hl_group, attributes)
return hl_group
end

--- Makes a highlight group link.
--- @param hl_group string: highlight group name
--- @param to string: highlight group name to link |:hl-link|
--- @return string # hl_group
function M.link(hl_group, to)
vim.api.nvim_set_hl(0, hl_group, {
link = to,
Expand Down

0 comments on commit 482d558

Please sign in to comment.