markdown_preview: Fix relative links in remote Markdown subfolders (#61438)
Closes #58270
In remote projects, Markdown previews resolved relative links from the
project root instead of the Markdown file's folder. Links worked for
files in the root but could fail or open the wrong file for files in
subfolders.
Zed now resolves these links from the Markdown file's folder. The fix
updates base path handling in `open_url_or_file`. Only Markdown Preview
passes a base path to this function.
I tested it on macOS with a Linux SSH host and on Windows with WSL.
Release Notes:
- Fixed relative links in Markdown previews for files in subfolders when
using SSH or WSL.
9d0ef37a25Smit Barmase committed on 7/22/2026, 9:10:58 AM· committed by GitHubparentb6dac6c