chore(build): auto-generate docs

This commit is contained in:
folke 2025-02-10 13:37:05 +00:00 committed by github-actions[bot]
parent a6d866ab72
commit ffdbcd6a88
2 changed files with 50 additions and 21 deletions

View file

@ -48,7 +48,20 @@ to the supported formats (all except PNG).
```lua
---@class snacks.image.Config
---@field file? string
{}
---@field wo? vim.wo|{} options for windows showing the image
{
wo = {
wrap = false,
number = false,
relativenumber = false,
cursorcolumn = false,
signcolumn = "no",
foldcolumn = "0",
list = false,
spell = false,
statuscolumn = "",
},
}
```
## 📚 Types
@ -63,7 +76,6 @@ to the supported formats (all except PNG).
---@class snacks.image
---@field id number
---@field buf number
---@field wins table<number, snacks.image.Dim>
---@field opts snacks.image.Config
---@field file string
---@field augroup number
@ -71,6 +83,16 @@ to the supported formats (all except PNG).
Snacks.image = {}
```
### `Snacks.image.dim()`
Get the dimensions of a PNG file
```lua
---@param file string
---@return number width, number height
Snacks.image.dim(file)
```
### `Snacks.image.health()`
```lua
@ -164,3 +186,10 @@ image:request(opts)
```lua
image:update()
```
### `image:wins()`
```lua
---@return number[]
image:wins()
```

View file

@ -596,23 +596,6 @@ Snacks.picker.pick({source = "files", ...})
---@field field? string
```
```lua
---@alias snacks.Picker.ref (fun():snacks.Picker?)|{value?: snacks.Picker}
```
```lua
---@class snacks.picker.Last
---@field cursor number
---@field topline number
---@field opts? snacks.picker.Config
---@field selected snacks.picker.Item[]
---@field filter snacks.picker.Filter
```
```lua
---@alias snacks.picker.history.Record {pattern: string, search: string, live?: boolean}
```
```lua
---@alias snacks.picker.Extmark vim.api.keyset.set_extmark|{col:number, row?:number, field?:string}
---@alias snacks.picker.Text {[1]:string, [2]:string?, virtual?:boolean, field?:string}
@ -689,6 +672,23 @@ It's a previewer that shows a preview based on the item data.
---@field preview? snacks.win.Config|{} preview window config
```
```lua
---@alias snacks.Picker.ref (fun():snacks.Picker?)|{value?: snacks.Picker}
```
```lua
---@class snacks.picker.Last
---@field cursor number
---@field topline number
---@field opts? snacks.picker.Config
---@field selected snacks.picker.Item[]
---@field filter snacks.picker.Filter
```
```lua
---@alias snacks.picker.history.Record {pattern: string, search: string, live?: boolean}
```
## 📦 Module
```lua
@ -2648,6 +2648,8 @@ Snacks.picker.actions.toggle_preview(picker)
Snacks.picker.actions.yank(picker, item, action)
```
## 📦 `snacks.picker.core.picker`
```lua
@ -2881,5 +2883,3 @@ Get the word under the cursor or the current visual selection
```lua
picker:word()
```