hugo-book icon indicating copy to clipboard operation
hugo-book copied to clipboard

mermaid: choosing <div> over <p> for styling flexibility

Open nnzv opened this issue 1 year ago • 1 comments

Enhance styling and centering by opting for <div> over <p>. For example, utilize the class div.mermaid with text-align: center; for positioning the Mermaid.js SVG image at the center of the container.

// filepath: assets/_custom.scss
div.mermaid {
    text-align: center;
}

nnzv avatar Oct 30 '23 06:10 nnzv

Hello! <p> is used to apply regular spacing (as many other blocks in markdown are rendered as paragraphs). How this will be different from p.mermaid {} class?

alex-shpak avatar Dec 04 '23 21:12 alex-shpak