zsviczian / obsidian-excalidraw-plugin

A plugin to edit and view Excalidraw drawings in Obsidian
4.13k stars 228 forks source link

FR: Native SVG without click-event-handlers #1265

Open lukemt opened 1 year ago

lukemt commented 1 year ago

Is your feature request related to a problem? Please describe. SVG Image does not render embeds. Native SVG overwrites the click handlers.

Describe the solution you'd like Maybe a fourth image type option would be cool: Native SVG without event handlers. A rendering option that would render all the embeds, but not allow interacting with them.

Additional context This is just a tiny suggestion and I'm not even sure if I will stick to it, but I have already implemented this as a snippet:

.markdown-source-view .excalidraw-svg svg,
.markdown-preview-view .excalidraw-svg svg {
  pointer-events: none;
}

So I personally don't need the feature (since I already have the snippet) but I share it because maybe others would like this

lukemt commented 1 year ago

I personally switched back to SVG Image for performance reasons.

zsviczian commented 1 year ago

yes, native SVG is a performance hit. That is why I did not enable it as default. Thanks for sharing the snippet.