Rounded border for hovered row in the file list #426
-
Is your feature request related to a problem? Please describeNo response Will you be willing to contribute this feature?
Describe the solution you'd likeHello, Would you consider supporting rounded borders around current and future selections, as such: This may really improve the feel of the tui. Describe alternatives you've consideredNo response Additional contextNo response |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 6 replies
-
Hmm, how did you make it rounded? 😂 |
Beta Was this translation helpful? Give feedback.
-
Oh, haha, I used a screenshot and colored in the edges. HAHAHA |
Beta Was this translation helpful? Give feedback.
-
demo.mp4Yazi allows you to rewrite most of the UI through UI plugins, and you can achieve this by extending the function Folder:linemode(area)
local lines = {}
for _, f in ipairs(self:by_kind(self.CURRENT).window) do
if f:is_hovered() then
-- You may want to change the "foreground color" here to adapt to your theme
lines[#lines + 1] = ui.Line { ui.Span(""):bg("reset"):fg("blue") }
break
else
lines[#lines + 1] = ui.Line {}
end
end
return ui.Paragraph(area, lines):align(ui.Alignment.RIGHT)
end Save those lines as a file, for example [plugins]
preload = [
"~/.config/yazi/ui.lua"
] This is just an example, please read the documentation about |
Beta Was this translation helpful? Give feedback.
demo.mp4
Yazi allows you to rewrite most of the UI through UI plugins, and you can achieve this by extending the
linemode
:Save those lines as a file, for example
~/.config/yazi/ui.lua
, and include it in theyazi.toml
: