mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-01-28 07:03:17 +08:00
merge fix: get classDefs only if diagram is in CLASSDEF_DIAGRAMS
This commit is contained in:
parent
b20602672e
commit
469d0f87be
@ -181,8 +181,8 @@ export const createCssStyles = (
|
||||
|
||||
// classDefs defined in the diagram text
|
||||
if (classDefs && Object.keys(classDefs).length > 0) {
|
||||
if (graphType === 'flowchart' || graphType === 'flowchart-v2' || graphType === 'graph') {
|
||||
const htmlLabels = config.htmlLabels || config.flowchart?.htmlLabels;
|
||||
if (CLASSDEF_DIAGRAMS.includes(graphType)) {
|
||||
const htmlLabels = config.htmlLabels || config.flowchart?.htmlLabels; // TODO why specifically check the Flowchart diagram config?
|
||||
|
||||
const cssHtmlElements = ['> *', 'span']; // TODO make a constant
|
||||
const cssShapeElements = ['rect', 'polygon', 'ellipse', 'circle']; // TODO make a constant
|
||||
|
Loading…
x
Reference in New Issue
Block a user