fix: bind self in stub arguments

Fixes https://github.com/yazi-rs/yazi-rs.github.io/issues/256
This commit is contained in:
sxyazi
2025-06-22 16:24:52 +08:00
parent 3d1efb7069
commit 42f64c01c4

View File

@@ -2738,7 +2738,7 @@ ya = ya
-- | | | | -- | | | |
-- | ------- | ----------------- | ------------------------------------------------ | -- | ------- | ----------------- | ------------------------------------------------ |
-- | Inherit | [`Style`](#style) | To call [`Style`](#style) methods on it directly | -- | Inherit | [`Style`](#style) | To call [`Style`](#style) methods on it directly |
---@field Span fun(value: string|self): ui.Span ---@field Span fun(value: string|ui.Span): ui.Span
-- `ui.Line` represents a line, consisting of multiple `ui.Span`s, and it accepts a table of them: -- `ui.Line` represents a line, consisting of multiple `ui.Span`s, and it accepts a table of them:
-- ```lua -- ```lua
-- ui.Line { ui.Span("foo"), ui.Span("bar") } -- ui.Line { ui.Span("foo"), ui.Span("bar") }
@@ -2757,7 +2757,7 @@ ya = ya
-- | | | | -- | | | |
-- | ------- | ----------------- | ------------------------------------------------ | -- | ------- | ----------------- | ------------------------------------------------ |
-- | Inherit | [`Style`](#style) | To call [`Style`](#style) methods on it directly | -- | Inherit | [`Style`](#style) | To call [`Style`](#style) methods on it directly |
---@field Line fun(value: string|ui.Span|self|(string|ui.Span|self)[]): ui.Line ---@field Line fun(value: string|ui.Span|ui.Line|(string|ui.Span|ui.Line)[]): ui.Line
-- `ui.Text` is used to represent multi-line text, it takes a table of `ui.Line`: -- `ui.Text` is used to represent multi-line text, it takes a table of `ui.Line`:
-- ```lua -- ```lua
-- ui.Text { ui.Line("foo"), ui.Line("bar") } -- ui.Text { ui.Line("foo"), ui.Line("bar") }