-
-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Info bar #142
Comments
Could this be something user configurable? I am thinking of the status bar configurations that vim and tmux have. For example perhaps configuration could look like this: [statusbar]
left = "TLS %t, Cert Size: %s"
center = "[%m]"
right = "%l/%L %p%%"
display = true # Display by default or not? And the statusbar could be rendered as:
Where (just for example)
Ideas of other items which could be included:
And perhaps at a later time:
|
Your proposal changes it from what I was picturing, mostly a debugging bar, into a full-blown feature. I like it. 😄 Going through your comment: I find "Info Bar" not a great name, but I don't know if "Status Bar" really fits either. Thoughts? Being able to align text is a nice thing to have, again it turns it into a UI element rather than just some debugging info. I'm still unsure what to do if the terminal width is less that the space needed to display the info though. I mentioned this in my original comment but it's a bit more confusing when there's text-alignment. I don't want the bar to be more than one line, I don't want the user to have to somehow select and scroll through it, I don't want it to move on its own marquee-style... maybe the user will just have increase their terminal size if they really want all that info. display = true # Display by default or not? This^^ is a good idea. I'm thinking off by default, so as not to change the way Amfora looks now. Those who want extra info can have it.
Good one, added to the top comment. See the possible infos I've added there, got ideas for any others?
This will be displayed at the top if favicons are enabled, I don't see the point.
Both sound good, added.
I don't understand these. I was thinking of having this as a second bar, right above the URL bar (aka the "bottom bar"), so the URL and all its parts are easily visible to the user. I've added an option for a decoded query string though, because that is not easily available. I also added one for Unicode domain, because likely I will have Unicode domains show up as punycoded in the URL bar.
Once #126 is added you'll be able to see this from
Good idea. This is easy to do right away if I use cview's format strings. cview is the library Amfora uses to create a TUI, and its format strings are defined here. This allows for nice things like italics and bold out of the box.
I'm not really interested in this, it seems a bit over the top complexity-wise. For the example you give about client certs, I'm thinking any data that doesn't apply will just be an empty string, so everything should look fine. Thanks for taking the time to think about this! It's gonna be a good feature. Note to self: The config format proposed should be able to be easily parsed by a regex that captures all percentage signs followed by letter(s), excluding double percentage signs. |
I wrote status bar because that was what I am most used to seeing being a heavy vim and tmux user. I wasn't trying to make a point by not using "info bar". I just have it in my head as "status bar" But info bar does have the advantage of working well with i. I don't have much of an opinion on the matter.
Yes, please no marquee. It's the only thing worse than a
That's the behavior I am used to from vim and tmux. I think that if users want to use a very narrow terminal, then they should make sure their format is very compact and barebones (perhaps using emoji as abbreviations). I could see an info line looking like this:
That's 74 characters, and I don't imagine too many people use smaller terminal widths. The only other thing I could think of to help would be to have versions of the mediatype tag split so that a users with a compact terminal do not need to display the parameters. With alignment, I would think that if/when the terminal is too small to fit it all , start chopping off information from the right field. Once that is gone, chop from the center. Then the left. If users use too narrow of a terminal, then they could put the most important info on the left, and less important on the right.
That's really sweet. That makes implementation very convenient.
That's fair. It's a lot of work for little benefit. The thing I was thinking with client certs was: what if I have a format string which displays a client cert like this:
You bet. I'm excited for it! As an aside: Do you think that information about proxies in use would be helpful? I've not tried proxies yet myself. |
This looks great! Might do it in my own config.
Done, I have one for the media type and one for the params now.
Sounds good to me.
No you're totally right. Adding a text or emoji prefix before the data will be very common, and there needs to be a way to remove that part entirely. I need to figure out a very simple format to define display text under a certain condition, and have no text otherwise. I don't think displaying another bit of text if a variable doesn't exist is needed, let me know if I'm wrong though. Would appreciate hearing about any formats that already have Go parsers, or a simple one you could make up. The Go template library could do this but I find ugly and too verbose for this use case.
Yep, on a proxied page it good be helpful to know what host the content is being proxied from, like |
I don't know of any existing go parsers that would be useful here. The simplest format I can think of is what Vim uses. It has "group" format marks
If the client cert expiration time (
I have never tried this, but I think you can make it a bit better by using
|
Thanks for the suggestions! Both of these look good, and I didn't know about |
It'd be nice to be able to see additional info about the current page. This could be achieved by having a separate bar above the bottom bar, that can be toggled with i.
Information that could be displayed
1.2
cache
ornetwork
lang
param using golang.org/x/text/language/display and display an English language version of the tag(s):English, Japanese
ECDSA
ECDSA
Questions
structs.Page
so it can be displayed again when the page is cached?See below for discussion on configuration and formatting.
The text was updated successfully, but these errors were encountered: