withfig / fig

Public issue tracker for Fig.
https://fig.io
MIT License
2.05k stars 63 forks source link

Nerd Fonts usage & fzf integration #795

Open drewauff opened 2 years ago

drewauff commented 2 years ago

Sanity checks

Feature Details

I lot of cli users also use Nerd Fonts, these fonts as you know already contain icons for file types, folders etc.

I would like to suggest that an option be added to allow for usage of these Nerd Font icons.

Also, I would like to be able to use Fig via fzf, that is, when Fig is triggered the popup is within fzf (with the exception of settings), fzf already makes use of Nerd Fonts and therefore the icons and filetype icons and provided too.

mschrage commented 2 years ago

Hey @drewauff! Thank you so much for these suggestions.

I lot of cli users also use Nerd Fonts, these fonts as you know already contain icons for file types, folders etc.

I would like to suggest that an option be added to allow for usage of these Nerd Font icons.

Would you like to replace the icons in the Fig popup with the Nerd Font equivalents? This is definitely possible.

Also, I would like to be able to use Fig via fzf, that is, when Fig is triggered the popup is within fzf (with the exception of settings), fzf already makes use of Nerd Fonts and therefore the icons and filetype icons and provided too.

Porting the autocomplete experience to fzf would be difficult to implement since all of the logic is currently written in TypeScript/React. I think this is out of scope for us right now.

However, I'd love to understand your preference for fzf over the popup window. Do you just prefer the aethetics or is there something about the user experience that we're missing?

drewauff commented 2 years ago

Its the aesthetics, seeing the standard "Finder" style icons in the popup just doesn't look, well, right. It "cheapens" the look, hence using Nerd Fonts. So a big YES to wanting to use Nerd Fonts for the popup icons and why not the text too.

As for fzf, simple, extensibility, appearance and performance. Also this would make the use of Nerd Fonts easier to implement.

I dont think porting to fzf, or giving users the choice of one or the other, is actually that hard. There have been a few plugins that have auto/live completing like Fig (autosuggestions is one, very cluttered, but it works). Some use popup menu style like Fig others display the content across the terminal screen.

I should note that autosuggestions is the only plugin ive come across that "works" with very little setup, literally, install -> add to .zshrc and restart session and thats it, it works, stupidly cluttered to the point of be unusable for me. I like a cleaner look. This is what Fig gives.

I appreciate your taking to respond to my post.

Thankyou.

mschrage commented 2 years ago

I think we can add a setting like autocomplete.icons [ glyph | native ] that configures whether we use Nerd Fonts or the current icons. We can pull in Nerd Fonts as a web font, so no changes are required to core macOS app.

To clarify, do you want all of the icons to be based on Nerd Fonts or just the file/folder icons?

Screen Shot 2022-01-19 at 2 58 37 PM

For instance, would you want this setting to change the icons for subcommands and options as well?

drewauff commented 2 years ago

Sounds good, I would think that the change would be "global" .

How about this, when listing flags just list flags no icon needed, the same for generic things that do not have or really need an icon, of course this can be an optional setting but one that would very much "declutter" the popup.

I must say the world needs more devs. I like you. Ready and willing to do what it takes to make a better product. Well done!

Almost everytime I open Fig's settings (fig settings) iTerm spews out this "text" 11;rgb:0000/0000/0000;1R

mschrage commented 2 years ago

Thanks for the kind words @drewauff!

Almost everytime I open Fig's settings (fig settings) iTerm spews out this "text" 11;rgb:0000/0000/0000;1R

This seems like a regression with the latest build. I've opened a new issue #806

drewauff commented 2 years ago

Sadly I've had to uninstall Fig (at least for the time being) reasons being :

I loved using Fig, but right now, at least for me its relatively unusable. Sorry.

mschrage commented 2 years ago

Hey @drewauff, thanks for letting us know. This is definitely not the expected behavior.

Would you be free to jump on a 1:1 debugging call? I'd love to figure out what's going on here. https://calendly.com/mschrage/30min

drewauff commented 2 years ago

I have just spent the last few hours going through system logs etc..as a former systems admin, I can tell you I have gone through everything I can think of.

The only conclusion is that my system is buttery smooth in all regards. No cpu or memory spikes.

Fig was perfect in the beginning, although I have to say that I did notice a little system wide lag, but nothing terrible. As time pass it got worse and worse.

I reset pram and smc etc..to no avail.

hopefully we can find a solution.

drewauff commented 2 years ago

Just a quick upgate, I

Today is day 3 of smoooth running, no cpu spike or memory hogging etc.

Thankyou for EVERYTHING! . Andy

mschrage commented 2 years ago

Other users with a similar issue:

I also found the styling of the suggestions jarring in relation to the command window.

Also linking #442 for reference.