Skip to content

Commit d3cecc6

Browse files
Fix custom checkbox type annotation
1 parent ff3e8e3 commit d3cecc6

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

lua/render-markdown/custom_checkbox.lua

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ local M = {}
66
---@return render.md.CustomCheckbox?
77
M.get_exact = function(value)
88
for _, checkbox in pairs(state.config.checkbox.custom) do
9-
---@diagnostic disable-next-line: undefined-field
109
if checkbox.text == value then
1110
return checkbox
1211
end
@@ -18,7 +17,6 @@ end
1817
---@return render.md.CustomCheckbox?
1918
M.get_starts = function(value)
2019
for _, checkbox in pairs(state.config.checkbox.custom) do
21-
---@diagnostic disable-next-line: undefined-field
2220
if vim.startswith(value, checkbox.text) then
2321
return checkbox
2422
end

lua/render-markdown/init.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ local M = {}
4949
---@class render.md.UserCheckbox
5050
---@field public unchecked? string
5151
---@field public checked? string
52-
---@field public custom? table<string, render.md.CustomCheckbox[]>
52+
---@field public custom? table<string, render.md.CustomCheckbox>
5353

5454
---@class render.md.UserConfig
5555
---@field public start_enabled? boolean

lua/render-markdown/types.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
---@class render.md.Checkbox
3232
---@field public unchecked string
3333
---@field public checked string
34-
---@field public custom table<string, render.md.CustomCheckbox[]>
34+
---@field public custom table<string, render.md.CustomCheckbox>
3535

3636
---@class render.md.Config
3737
---@field public start_enabled boolean

0 commit comments

Comments
 (0)