refactor: address emmylua diagnostics
This commit is contained in:
+10
-9
@@ -1,3 +1,4 @@
|
||||
---@diagnostic disable: param-type-mismatch, missing-fields
|
||||
local blink = require("blink.cmp")
|
||||
blink.setup({
|
||||
completion = {
|
||||
@@ -32,15 +33,15 @@ blink.setup({
|
||||
return ctx.label
|
||||
end,
|
||||
highlight = function(ctx)
|
||||
local highlights = {
|
||||
{
|
||||
0,
|
||||
#ctx.label,
|
||||
group = ctx.deprecated
|
||||
and "BlinkCmpLabelDeprecated"
|
||||
or "BlinkCmpLabel",
|
||||
},
|
||||
}
|
||||
---@type blink.cmp.DrawHighlight[]
|
||||
local highlights = {}
|
||||
table.insert(highlights, {
|
||||
0,
|
||||
#ctx.label,
|
||||
group = ctx.deprecated
|
||||
and "BlinkCmpLabelDeprecated"
|
||||
or "BlinkCmpLabel",
|
||||
})
|
||||
for _, idx in ipairs(ctx.label_matched_indices) do
|
||||
table.insert(highlights, {
|
||||
idx,
|
||||
|
||||
Reference in New Issue
Block a user