# Mermaid rendering ignore UpdateElementStyle

**URL:** <https://forum.obsidian.md/t/mermaid-rendering-ignore-updateelementstyle/65339>\
**Category:** Bug reports\
**Tags:** ui-ux, repro, mermaid\
**Created:** [August 18, 2023, 1:30pm UTC](https://forum.obsidian.md/t/mermaid-rendering-ignore-updateelementstyle/65339 "2023-08-18T13:30:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mipnamic](https://forum.obsidian.md/user_avatar/forum.obsidian.md/mipnamic/32/51972_2.png) [@mipnamic](https://forum.obsidian.md/u/mipnamic)\
**Post date:** [August 18, 2023, 1:30pm UTC](https://forum.obsidian.md/t/mermaid-rendering-ignore-updateelementstyle/65339/1 "2023-08-18T13:30:00Z")

</div>

### Steps to reproduce

Create a block like the following:

```mermaid
C4Context
	title Example
	System(object, "Sample object")
	UpdateElementStyle(object, $fontColor="white", $bgColor="lightgrey")

```

### Did you follow the [troubleshooting guide](https://forum.obsidian.md/t/about-the-bug-reports-category/24/10)? [Y/N]

Yes

### Expected result

Text of the diagram should become “white”.

### Actual result

Text shows in the default colour.

### Environment

SYSTEM INFO:  
Obsidian version: v1.3.5  
Installer version: v1.3.4  
Operating system: Darwin Kernel Version 22.5.0: Mon Apr 24 20:53:44 PDT 2023; root:xnu-8796.121.2~5/RELEASE\_ARM64\_T8103 22.5.0  
Login status: logged in  
Catalyst license: none  
Insider build toggle: off  
Live preview: on  
Legacy editor: off  
Base theme: light  
Community theme: none  
Snippets enabled: 0  
Restricted mode: on

RECOMMENDATIONS:  
none

* * *

### Additional information

It doesn’t work locally nor in the published version on a site.

---

<div class="post-metadata">

**Author:** ![Jopp](https://forum.obsidian.md/letter_avatar_proxy/v4/letter/j/8e7dd6/32.png) [@Jopp](https://forum.obsidian.md/u/Jopp)\
**Post date:** [August 21, 2023, 11:11am UTC](https://forum.obsidian.md/t/mermaid-rendering-ignore-updateelementstyle/65339/2 "2023-08-21T11:11:01Z")

</div>

Well, mermaid diagrams aren’t top priority and “just” an implementation of [https://mermaid.js.org/](https://mermaid.js.org/).

In the meantime, we need to wait patiently for an updated version of mermaid diagrams in Obsidian. Also in my opinion, Mermaid diagrams should get more priority over other features.

---

<div class="post-metadata">

**Author:** ![WhiteNoise](https://forum.obsidian.md/user_avatar/forum.obsidian.md/whitenoise/32/11_2.png) [@WhiteNoise](https://forum.obsidian.md/u/WhiteNoise)\
**Post date:** [August 21, 2023, 3:48pm UTC](https://forum.obsidian.md/t/mermaid-rendering-ignore-updateelementstyle/65339/3 "2023-08-21T15:48:46Z")

</div>

May be related to:

> [@Mermaid: Custom theme not working](https://forum.obsidian.md/t/mermaid-custom-theme-not-working/45583):
>
> Steps to reproduce Add the following legal mermaid graph in a code block: %%{init: {'theme': 'forest'} }%% graph LR A[Foo] --\> B[Bar] B --\> C[Baz] C --\> B Expected result A graph with three boxes with a green:ish theme Actual result Error message: Error parsing Mermaid diagram! Unsupported color format: "var(--background-primary)" If one removed the initial init then the mermaid graph works as expected using the default theme (which doesn’t play well with a dark background). Environment …

and

> [@Mermaid - emoji being inverted if Obsidian theme is set to Dark](https://forum.obsidian.md/t/mermaid-emoji-being-inverted-if-obsidian-theme-is-set-to-dark/111799):
>
> Steps to reproduce Change Obsidian theme to Dark Create a Mermaid diagram that features emojis, such as the below: flowchart TD Idea --\> visual(Visual\<br\>👁️) Idea --\> verbal(Verbal\<br\>speech_balloon) visual --\> recall(Recall\<br\>light_bulb) verbal --\> recall Did you follow the troubleshooting guide? [Y/N] Yes, issue can be replicated in the Sandbox Vault. Expected result Emojis are displayed as they normally would depending on the operating system and throughout the rest of Obsidian. Actual result Emoji colours…

---

<div class="post-metadata">

**Author:** ![WhiteNoise](https://forum.obsidian.md/user_avatar/forum.obsidian.md/whitenoise/32/11_2.png) [@WhiteNoise](https://forum.obsidian.md/u/WhiteNoise)\
**Post date:** [October 19, 2026, 12:36am UTC](https://forum.obsidian.md/t/mermaid-rendering-ignore-updateelementstyle/65339/4 "2026-10-19T00:36:31Z")

</div>

will be possible in v1.15. ETA unknown
