Closed YodaEmbedding closed 1 year ago
Workaround is to modify $HOME/.config/yazi/theme.toml
to add a space after every icon "manually".
[icons]
"Desktop/" = " "
"Documents/" = " "
"Downloads/" = " "
"Pictures/" = " "
"Music/" = " "
"Movies/" = " "
"Videos/" = " "
"Public/" = " "
"Library/" = " "
"Development/" = " "
".config/" = " "
# Git
".git/" = " "
".gitignore" = " "
".gitmodules" = " "
".gitattributes" = " "
# Dotfiles
".DS_Store" = " "
".bashrc" = " "
".bashprofile" = " "
".zshrc" = " "
".zshenv" = " "
".zprofile" = " "
".vimrc" = " "
# Text
"*.txt" = " "
"*.md" = " "
# Archives
"*.zip" = " "
"*.tar" = " "
"*.gz" = " "
"*.7z" = " "
# Audio
"*.mp3" = ""
"*.flac" = ""
"*.wav" = ""
# Movies
"*.mp4" = " "
"*.mkv" = " "
"*.avi" = " "
"*.mov" = " "
# Images
"*.jpg" = " "
"*.jpeg" = " "
"*.png" = " "
"*.gif" = " "
"*.webp" = " "
"*.avif" = " "
"*.bmp" = " "
"*.ico" = " "
"*.svg" = " "
# Programming
"*.c" = " "
"*.cpp" = " "
"*.h" = " "
"*.hpp" = " "
"*.rs" = " "
"*.go" = " "
"*.py" = " "
"*.js" = " "
"*.ts" = " "
"*.tsx" = " "
"*.jsx" = " "
"*.rb" = " "
"*.php" = " "
"*.java" = " "
"*.sh" = " "
"*.fish" = " "
"*.swift" = " "
"*.vim" = " "
"*.lua" = " "
"*.html" = " "
"*.css" = " "
"*.scss" = " "
"*.json" = " "
"*.toml" = " "
"*.yml" = " "
"*.yaml" = " "
"*.ini" = " "
"*.conf" = " "
# Default
"*" = " "
"*/" = " "
Is this because of the font? They shouldn't be so crowded imho
Yes, looks like the issue is only with Iosevka which is more horizontally squished compared to, e.g., Roboto Mono.
Looks like Telescope.nvim (which also uses devicons) always outputs <icon><space><space><text>
to avoid this issue.
Where can I download this font? I'd like to try replicating it.
ttc-iosevka
should be sufficient. I also have ttf-iosevka-nerd
, but it doesn't look necessary to reproduce.
Hey, I've added a new Folder:icon()
API. You can now create a simple UI plugin and apply your styles within it:
-- ~/.config/yazi/ui.lua
function Folder:icon(file) return ui.Span(" " .. file:icon() .. " ") end
and then import it:
# ~/.config/yazi/yazi.toml
[plugins]
preload = [
"~/.config/yazi/ui.lua"
]
I tested the PR. Works for me.
I'm going to lock this issue because it has been closed for 30 days. ⏳ This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Icons could use another space afterwards.
OS: Arch Font: Iosevka, size 15 Other installed fonts: ttf-font-awesome Terminal: Alacritty