Open bitsofmymind opened 3 years ago
Thanks for reporting and suggesting a fix. You can create a pull if you like.
@JeroenDeDauw This suggests adding something to common.js Probably a solution could be added to Mermaid code itself. Something to integrate into 3.0.0 (#48) though not a blocker
This looks like a bug, not like a breaking change, so I do not feel in any way compelled to work on this by 3.0 release
This looks like a bug, not like a breaking change, so I do not feel in any way compelled to work on this by 3.0 release
No worries. That's why I mentioned: though not a blocker.
Thank you gents,
In fact, the proposed solutions works "most of the time" but sometimes doesn't, which leads me to believe that it browser timing sensitive. In short, it's an ugly hack.
The problem indeed seems to lie with the Flow extension. I figured I'd report it in case someone came up with a better fix.
In fact, the proposed solutions works "most of the time" but sometimes doesn't, which leads me to believe that it browser timing sensitive. In short, it's an ugly hack.
Still much better than nothing and great that you shared this interim solution.
The problem indeed seems to lie with the Flow extension. I figured I'd report it in case someone came up with a better fix.
I suspect this is may very well be the case. Keeping fingers crossed since development for Flow has basically been reduced to hot fixes only afaik.
Setup and configuration
Issue
This is a bit of a corner case, but we've found out that Mermaid does not load when called within a Flow (StructuredDiscussions) topic. The syntax does not work standalone and needs to be wrapped in a Template, but that's probably a Flow issue.
However, when wrapped in a Template and called from a Flow topic, the mermaid librairies are not loaded.
Adding the following to Mediawiki:Common.js seems to get it to work: