javalent / admonitions

Adds admonition block-styled content to Obsidian.md
MIT License
1.04k stars 67 forks source link

Incorrect callout rendering in "new window" view #344

Open juliandeleonguerrero opened 1 month ago

juliandeleonguerrero commented 1 month ago

Check for existing bug reports before submitting.

Expected Behavior

Experienced using custom callouts, default callouts do not appear affected. Custom callout should use icon and custom color designated by the admonition plugin. See attached screenshot for how it renders normally, within the main Obsidian window.

image

Current behaviour

Confirmed on Windows 11. Custom callouts made via admonition appear to default to the default color for callouts, when popped out into a new window view:

image

Icon and color are incorrect.

Strangely enough, the plugin functions correctly in the new window view if you insert an admonition, rather than using the callout functionality present within Obsidian.

image

image

I have attached the Obsidian vault I used to test this. It is a fresh Obsidian vault with a fresh admonition install, though I had to import my previous custom callouts.

default_obsidian.zip

Reproduction

  1. Create a new Obsidian vault, or maybe a sandbox vault.
  2. Install the Admonitions plugin.
  3. Import or create a custom admonition type (tested with both). Specify a custom color and icon.
  4. Add custom admonitions to notes, using callout syntax.
  5. Open note in new window, as screenshot: image
  6. Callout will render incorrectly.

Which Operating Systems are you using?

Obsidian Version Check

1.5.12, installer version 1.5.3

Plugin Version

10.3.1

Confirmation

Possible solution

No response

juliandeleonguerrero commented 1 month ago

What's really strange 🤔 It rendered the custom icon the first time, but not the subsequent times... it also used a different icon in subsequent instances. I'm just now realizing that