Skip to content
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

Ctrl+clicking URLs partially out of viewport not working as expected #18177

Open
JeffreyCA opened this issue Nov 11, 2024 · 3 comments
Open

Ctrl+clicking URLs partially out of viewport not working as expected #18177

JeffreyCA opened this issue Nov 11, 2024 · 3 comments
Assignees
Labels
Area-Interaction Interacting with the vintage console window (as opposed to driving via API or hooks) Issue-Bug It either shouldn't be doing this or needs an investigation. Product-Terminal The new Windows Terminal.

Comments

@JeffreyCA
Copy link
Member

Windows Terminal version

1.22.2912.0

Windows build number

10.0.22635.4445

Other Software

No response

Steps to reproduce

  1. Open Windows Terminal

  2. Resize Terminal window to a small size

  3. Press 'Enter' key until the active command prompt (with blinking cursor) reaches the last visible row in the window:
    Image

  4. Run a command with a long URL, like: echo 'https://github.com/microsoft/terminal/blob/main/src/cascadia/TerminalCore/lib/terminalcore-lib.vcxproj'

  5. Ensure the URL wraps to span 2 or more lines. If not, resize the window to reduce the width.
    Image

  6. Scroll up one line so that only the first line of the wrapped URL is visible: Image

  7. Ctrl+click the visible part of the URL

Expected Behavior

It should navigate to the full URL (https://github.com/microsoft/terminal/blob/main/src/cascadia/TerminalCore/lib/terminalcore-lib.vcxproj)

Actual Behavior

It navigates to the part of the URL that's visible (https://github.com/microsoft/terminal/bl), which is often invalid

@JeffreyCA JeffreyCA added Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Nov 11, 2024
Copy link

We've found some similar issues:

If any of the above are duplicates, please consider closing this issue out and adding additional context in the original issue.

Note: You can give me feedback by 👍 or 👎 this comment.

@JeffreyCA
Copy link
Member Author

This seems to be similar to #9089, but that was closed by the original author without a fix

@carlos-zamora carlos-zamora added this to the Terminal v1.23 milestone Nov 20, 2024
@carlos-zamora carlos-zamora added Area-Interaction Interacting with the vintage console window (as opposed to driving via API or hooks) Product-Terminal The new Windows Terminal. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Nov 20, 2024
@carlos-zamora carlos-zamora self-assigned this Nov 20, 2024
@carlos-zamora
Copy link
Member

Thanks for filing! I was actually just taking a look at that code earlier. We only look one past the end of the current viewport, so we can just expand on that.

Long-term, we should perform the regex search on hover. The regex system we have is pretty performant so there shouldn't be any performance concerns there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Interaction Interacting with the vintage console window (as opposed to driving via API or hooks) Issue-Bug It either shouldn't be doing this or needs an investigation. Product-Terminal The new Windows Terminal.
Projects
None yet
Development

No branches or pull requests

2 participants