Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Support Typora-style mermaid markdown rendering #32

Open
ClSlaid opened this issue Jul 10, 2021 · 5 comments
Open

[FEATURE] Support Typora-style mermaid markdown rendering #32

ClSlaid opened this issue Jul 10, 2021 · 5 comments
Labels
enhancement New feature or request

Comments

@ClSlaid
Copy link

ClSlaid commented Jul 10, 2021

Describe the feature you want

  • use typora-style mermaid markdown rending.
    Currently, most Hugo themes use short-codes as their way of importing multimedia content, and it does useful and convenient.
    However, as a visual studio code user (or markdown preview enhanced user, more precisely), shortcodes are not working in its editor; Typora uses the following syntax to import mermaid graphs.
```mermaid
#mermaid diagram scripts
```    e.g.

Then the editor will directly render them into graphs, what you see is what you got.

图片

What if the theme could directly render such syntax of markdown text? then we needn't search through the whole text and replace them one by one.

@ClSlaid ClSlaid added the enhancement New feature or request label Jul 10, 2021
@ClSlaid
Copy link
Author

ClSlaid commented Jul 10, 2021

I've tried adding such a feature into Hugo-theme-even in February, however, the author seems to have abandoned the project and did not take even a look into my pull request, maybe the change in the PR may be of help to you...

@khusika
Copy link
Owner

khusika commented Jul 11, 2021

is this related to the 3rd party markdown editor?

@ClSlaid
Copy link
Author

ClSlaid commented Jul 11, 2021

is this related to the 3rd party markdown editor?

Not at all, I mean if the theme could render mermaid code blocks as mermaid shortcodes, it'll be of convenience.

@khusika
Copy link
Owner

khusika commented Jul 11, 2021

Not at all, I mean if the theme could render mermaid code blocks as mermaid shortcodes, it'll be of convenience.

Did you mean converting FeelIt default codeblock?

from

{{< mermaid >}}
{{< /mermaid >}}

into

```mermaid

@ClSlaid
Copy link
Author

ClSlaid commented Jul 12, 2021

Not at all, I mean if the theme could render mermaid code blocks as mermaid shortcodes, it'll be of convenience.

Did you mean converting FeelIt default codeblock?

from

{{< mermaid >}}
{{< /mermaid >}}

into

```mermaid

Yes, to be more precise, I mean treat

```mermaid

as

{{ < mermaid > }}
{{ </mermaid>}}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants