zellij-org / zellij

A terminal workspace with batteries included
https://zellij.dev
MIT License
20.66k stars 639 forks source link

Can't click-and-open url links in zellij #2425

Open LYK-love opened 1 year ago

LYK-love commented 1 year ago

Basic information

zellij --version: 0.31.4 uname -av or ver(Windows): Darwin ``

List of programs you interact with: alacritty --version: alacritty 0.10.1 iTerm2 version: 3.5.0

Further information If I execute some local searver in my terminal, it wil usually give me a url, like localhost:4000, by clicking it, I can open that url in my explorer. This behavior is commen in explorers and terminals. However, if such url shows in Zellij, no matter in "pane" or "tab", the url can't be opened by easily clicking it. It's presented just as normal text. I have tested it in Zellij and tmux. In tmux, the "click-and-open url" behavior is normal, no matter in "window" or "pane". I also tested it in different terminal emulaters like Alacritty and iTerms2. The result has nothing to do with them. So this problem must lie in Zellij itself, not related to other factors.

Here're some screenshots:

In tmux, this link can be clicked-and-opened:

image

And in Zellij, when my mouse move to that link, I can't see any rendering which implies that I can click and open it like in explorer.

image

(Due to the limit of my screenshot tool, my cursor image can't be recorded. But you can test it in your way.)

jaeheonji commented 1 year ago

I'm not the main user of Alacritty, so I don't know the details, but in Windows Terminal, URL links work even inside zellij. So now it seems to depend on Terminal's own feature.

So I consider this to be an enhancement rather than a bug. Thanks for reporting. and I'll change the label.

alissonbrunosa commented 1 year ago

Hi, I am having the same issue with Kitty and Alacritty. Outside zellij, the link is clickable and works as it should. Holding the key shift make it work, but it would be nice to have the same Tmux behaviour.

$ zellij --version
-> zellij 0.37.2
$ kitty --version
-> kitty 0.26.5 created by Kovid Goyal
tlinford commented 1 year ago

In tmux as far as I can tell, clicking without shift only works when mouse mode is off. If you turn it off in zellij it's the same.

d1onys1us commented 1 year ago

In tmux as far as I can tell, clicking without shift only works when mouse mode is off. If you turn it off in zellij it's the same.

yeah i had the same behavior here, disabling mouse mode helped. however if i am using multiple vertical panes the link is "cut off" (like if the link gets word wrapped, it only copies the part up until the border of the pane) and when i try to click it, it only opens up the cut off version of url. i'm wondering if there is a workaround for this?

tlinford commented 1 year ago

ah i see.. that's a bug!

alissonbrunosa commented 1 year ago

In tmux as far as I can tell, clicking without shift only works when mouse mode is off. If you turn it off in zellij it's the same.

Hey @tlinford, You're right, I completely missed that mouse support is off by default on TMUX. Can confirm that the behaviour is the same with mouse_mode false on Zellij

Vatson112 commented 7 months ago

Hi @alissonbrunosa

I confirm this behavior again with

zellij 0.39.2
alacritty 0.13.1

With mouse_mode true links are not opened by clicking it.

With mouse_mode false links opened normally.

It would be nice to open links in both modes.

yarcod commented 5 months ago

... i am using multiple vertical panes the link is "cut off" (like if the link gets word wrapped, it only copies the part up until the border of the pane) and when i try to click it, it only opens up the cut off version of url. i'm wondering if there is a workaround for this?

I just wanted to chime in that I've experienced this exact thing as well. Clicking links in general do work for me however, using latest Zellij and Alacritty.

HaroldArpanet commented 14 hours ago

Hey I have the same issue in Alacritty. Versions: