mirror of
https://github.com/kristoferssolo/solorice.git
synced 2026-02-04 06:32:03 +00:00
Update 2025-10-31
Update 2025-10-09 Update 2025-10-11 feat: add rose-pine gtk themes Update 2025-10-16 Update 2025-10-23 Fix desktop niri Update 2025-10-31
This commit is contained in:
@@ -50,6 +50,8 @@ end)
|
||||
local M = {
|
||||
keys = {
|
||||
{ on = "q", run = "quit" },
|
||||
{ on = "<Esc>", run = "quit" },
|
||||
{ on = "<Enter>", run = { "enter", "quit" } },
|
||||
|
||||
{ on = "k", run = "up" },
|
||||
{ on = "j", run = "down" },
|
||||
|
||||
@@ -15,7 +15,7 @@ Preview file types using `rich` command in Yazi. This plugin allows preview for
|
||||
## Requirements
|
||||
|
||||
- [Yazi](https://github.com/sxyazi/yazi) v25.4.8 or higher.
|
||||
- [rich-cli](https://github.com/Textualize/rich) v13.7.1 or higher.
|
||||
- [rich-cli](https://github.com/Textualize/rich-cli) v13.7.1 or higher.
|
||||
|
||||
## Installation
|
||||
|
||||
|
||||
@@ -42,9 +42,10 @@ function M:peek(job)
|
||||
ya.emit("peek", { math.max(0, i - limit), only_if = job.file.url, upper_bound = true })
|
||||
else
|
||||
lines = lines:gsub("\t", string.rep(" ", rt.preview.tab_size))
|
||||
ya.preview_widgets(job, {
|
||||
ui.Text.parse(lines):area(job.area):wrap(rt.preview.wrap == "yes" and ui.Text.WRAP or ui.Text.WRAP_NO),
|
||||
})
|
||||
ya.preview_widget(
|
||||
job,
|
||||
ui.Text.parse(lines):area(job.area):wrap(rt.preview.wrap == "yes" and ui.Wrap.YES or ui.Wrap.NO)
|
||||
)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user