markdown-viewer / markdown-viewer/obsidian

预览时无法显示 Obsidian 图片嵌入

Open
#2 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
No language data
Stars
20
Forks
5
PR merge metrics
No merged PRs in 30d

Description

问题描述

在 Obsidian 中使用该插件预览 Markdown 时,Obsidian 原生的图片嵌入没有被正确展示。

同一篇笔记在 Obsidian 自带阅读/预览视图中可以正常显示图片,但在 Markdown Viewer 预览中只显示破图占位和图片 alt 文本。

复现方式

  1. 在 Obsidian 笔记中插入本地图片,例如:
![[外呼管控 G01 切量阶段总览.png]]

或使用 Obsidian vault 内的相对图片路径。

  1. 打开 Markdown Viewer 预览该笔记。
  2. 查看图片位置。

当前表现

图片没有渲染出来,预览区域只显示破图图标/占位文本,例如:

外呼管控 G01 切量阶段总览

期望表现

Markdown Viewer 预览应与 Obsidian 自带预览一致,能够解析并显示 Obsidian vault 中的图片资源,至少支持:

  • Obsidian wikilink 图片嵌入:![[image.png]]
  • vault 内相对路径图片:![](path/to/image.png)

补充说明

截图中的对比现象是:左侧 Obsidian 预览可以正常显示流程图,右侧 Markdown Viewer 预览同一位置显示为破图占位。

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue in Markdown Viewer with both ![[image.png]] and a vault-relative ![](path/to/image.png) reference, comparing the result with Obsidian’s preview. Trace how the preview resolves and renders local image resources; done means both forms display the vault image instead of a broken-image placeholder and alt text.

Written by the indexing model from the issue text.

Assessment

Tech stack
markdown
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.