Mermaid gitgraph doesn't support TB on mobile

Steps to reproduce

In the mobile app (possibly not on iOS) create a mermaid code block (or find an existing one that meets the criteria) and write out a gitGraph diagram in the top to bottom direction.
Like so:

```mermaid
gitgraph TB:
  commit
  commit
  branch etc
```

Did you follow the troubleshooting guide? [Y/N] Yes

Expected result

It should render a git graph, but vertically, as stated in the mermaid.js documentation.

Actual result

The mermaid renderer throws a parse error, which doesn’t occur on desktop.

Error parsing Mermaid diagram!

Parse error on line 1:
gitGraph TB:  commit id: "c9
---------^
Expecting 'EOF', ':', 'DIR', 'NL', got 'ID'

Environment

SYSTEM INFO:
	Operating system: android 14 (Google Pixel 6a)
	Obsidian version: 1.4.16 (114)
	API version: v1.4.16
	Login status: not logged in
	Live preview: on
	Legacy editor: off
	Base theme: dark
	Community theme: none
	Snippets enabled: 3
	Restricted mode: on

RECOMMENDATIONS:
	Custom theme and snippets: for cosmetic issues, please first try updating your theme and disabling your snippets. If still not fixed, please try to make the issue happen in the Sandbox Vault or disable community theme and snippets.

Additional information

I have all my snippets disabled, and yet the debug info shows 3 loaded even if I restart the app. Pretty weird.

Obsidian 1.4.x uses still an older version of mermaid. Obsidian 1.5.x will have updated mermaid.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.