Skip to content

fix: resolve folder images from the active document - #2033

Open
xiaofeilovecoding wants to merge 1 commit into
backnotprop:mainfrom
xiaofeilovecoding:fix/folder-image-base-2006
Open

xiaofeilovecoding wants to merge 1 commit into
backnotprop:mainfrom
xiaofeilovecoding:fix/folder-image-base-2006

Conversation

@xiaofeilovecoding

Copy link
Copy Markdown

Fixes #2006.

Resolve relative Markdown images from the document currently open in a folder or bundle session. Reuse the existing cross-platform directory helper, while preserving the session base for single-file content.

Validation:

  • Original implementation: the two new nested-document cases return HTTP 404 from the real image reader; the single-file/remote-image case passes.
  • Fixed implementation: 39 related tests pass, including all seven bundle tests. The regressions navigate the file tree and read the actual rendered image URLs, checking distinct PNG bytes after switching directories.
  • A focused editor typecheck reports the same 24 diagnostics on the original and fixed source. Full workspace typecheck, Ubuntu CI/build and real-host browser testing were not run locally.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Folder annotate resolves markdown image paths against the session root, not the document's own directory

1 participant