Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
8603bdd
feat(themes)!: make redux-color the default theme
ashishjain0512 Aug 27, 2026
775a392
chore(changeset): mark the default-theme change as major
ashishjain0512 Aug 27, 2026
5de5292
fix(themes): address review on making redux-color the default
ashishjain0512 Aug 28, 2026
bceca3c
feat(look)!: make neo the default look
ashishjain0512 Aug 28, 2026
da796a8
fix(themes): let base honour an explicit nodeBorder under the neo look
ashishjain0512 Aug 28, 2026
c3ee3c7
fix(themes): clear four pre-existing defects the default flip makes v…
ashishjain0512 Aug 28, 2026
a66a5dd
fix(themes): validate look in the ER and requirement stylesheets
ashishjain0512 Aug 28, 2026
c831bac
refactor: hand the ER/requirement CSS-generation fixes to a standalon…
ashishjain0512 Aug 28, 2026
4b34808
docs(changeset): shorten the default-theme changesets
ashishjain0512 Aug 28, 2026
46f1c5c
Merge branch 'develop' into claude/redux-color-default-theme
ashishjain0512 Aug 28, 2026
1282309
fix(themes): address the CodeRabbit review on #8148
ashishjain0512 Aug 28, 2026
c76974d
Merge remote-tracking branch 'origin/develop' into claude/redux-color…
ashishjain0512 Aug 28, 2026
16b9a7d
feat(themes): colour swimlane lanes in the redux colour themes
ashish4mc Aug 31, 2026
0c43a13
Merge branch 'claude/redux-color-default-theme' into claude/swimlanes…
ashish4mc Aug 31, 2026
431141f
fix(themes): fill handDrawn lane bodies, and pin tsc-check's floating…
ashish4mc Aug 31, 2026
2d33f2a
chore(dev-explorer): offer every registered theme, and darken the can…
knsv Aug 31, 2026
dbd5adf
Merge pull request #8176 from mermaid-js/claude/swimlanes-redux-color…
ashishjain0512 Aug 31, 2026
75e6c30
feat(usecase): colour use case diagrams by role
knsv Aug 31, 2026
550394a
fix(usecase): stamp a rect colour slot only where one was assigned
knsv Aug 31, 2026
0f7934f
Merge pull request #8177 from mermaid-js/chore/dev-explorer-dark-themes
ashishjain0512 Aug 31, 2026
e0e29b6
Merge pull request #8178 from mermaid-js/feature/8175_usecase-redux-c…
ashishjain0512 Aug 31, 2026
9bd2ebc
fix(sequence): stop the theme forcing bold note text
knsv Aug 31, 2026
db17c48
fix(themes): stop the rect section band drawing white on white
knsv Aug 31, 2026
f5af413
fix(sequence): draw the stick-figure actor full size on the neo look
knsv Aug 31, 2026
ce0302d
fix(block): apply the redux colour palette to block diagrams
knsv Aug 31, 2026
d1a19b0
chore(dev-diagrams): add sequence fixtures for the neo/redux fixes
knsv Aug 31, 2026
524b7c6
fix(sequence): inset the stick figure inside its box at 0.8
knsv Aug 31, 2026
25b2b03
fix(sequence): inset the actor only on neo, leaving classic alone
knsv Aug 31, 2026
adc6315
fix(block): colour composites only, matching the flowchart
knsv Aug 31, 2026
31e6260
fix(sequence): give every participant one lifeline rule on neo
knsv Aug 31, 2026
b02f198
fix(sequence): put the label-below shapes on one baseline on neo
knsv Aug 31, 2026
cb9e009
fix(sequence): centre the round icons alike on neo
knsv Aug 31, 2026
5f501cb
fix(sequence): replace per-shape vertical guesswork with a band model
knsv Aug 31, 2026
0ad302c
fix(sequence): remove the legacy translate nudges the band model missed
knsv Aug 31, 2026
b8325ae
chore: update the changeset to describe the final band-model behaviour
knsv Aug 31, 2026
6344095
fix(sequence): address the review on #8185
knsv Aug 31, 2026
3802472
fix(themes): colour venn circles in the redux colour themes
ashish4mc Aug 31, 2026
53f4585
chore: trim comments to one or two lines
ashish4mc Aug 31, 2026
721b837
chore: trim comments to one or two lines
ashish4mc Aug 31, 2026
2878cf3
feat(themes): give state composites and concurrency regions a palette…
ashishjain0512 Aug 31, 2026
5f8effe
fix(state): declare the jison import as untyped in the colour-slot spec
ashishjain0512 Aug 31, 2026
94b02f4
Merge pull request #8190 from mermaid-js/claude/redux-color-comment-trim
ashishjain0512 Aug 31, 2026
9053495
Merge pull request #8189 from mermaid-js/claude/redux-color-venn
ashishjain0512 Aug 31, 2026
e94c3b8
Merge remote-tracking branch 'origin/develop' into claude/redux-color…
ashishjain0512 Aug 31, 2026
cac6b15
Merge branch 'claude/redux-color-default-theme' into claude/redux-col…
ashishjain0512 Aug 31, 2026
c1c1199
Merge branch 'develop' into claude/redux-color-default-theme
ashishjain0512 Aug 31, 2026
2120b84
Merge branch 'claude/redux-color-default-theme' into claude/redux-col…
ashishjain0512 Aug 31, 2026
121cac6
Merge branch 'develop' into claude/redux-color-default-theme
ashishjain0512 Aug 31, 2026
13bd73d
Merge pull request #8181 from mermaid-js/fix/block-fixes
ashishjain0512 Aug 31, 2026
48d839e
Merge pull request #8185 from mermaid-js/fix/sequence-fixes
ashishjain0512 Aug 31, 2026
82deff7
fix(themes): address the CodeRabbit and sisyphus-bot review on #8191
ashishjain0512 Sep 1, 2026
3d25846
fix(state): let handDrawn concurrency regions take the palette
ashishjain0512 Sep 1, 2026
2935427
Merge pull request #8191 from mermaid-js/claude/redux-color-state-com…
ashishjain0512 Sep 1, 2026
813c766
feat(config): default theme, look and layout per diagram type
ashishjain0512 Sep 1, 2026
24ddc86
feat(config): take the swimlane layout from the schema, and always fa…
ashishjain0512 Sep 1, 2026
6fc9008
chore: trim comments to one or two lines
ashishjain0512 Sep 1, 2026
b2de362
Merge remote-tracking branch 'origin/claude/redux-color-default-theme…
ashishjain0512 Sep 1, 2026
90d5796
fix(config): address the CodeRabbit and sisyphus-bot review on #8193
ashishjain0512 Sep 1, 2026
0afa5ee
test(e2e): cover per-diagram appearance on a shared page
ashishjain0512 Sep 1, 2026
c5d4b9c
fix(config): guard the theme registry with hasOwn, not `in`
ashishjain0512 Sep 1, 2026
3569e55
Merge pull request #8193 from mermaid-js/claude/per-diagram-appearanc…
ashishjain0512 Sep 1, 2026
846fd65
feat(agentflow): take the redux colour palette
knsv Sep 1, 2026
5660fc7
Merge claude/redux-color-default-theme into fix/agentflow-redux-colors
knsv Sep 1, 2026
ea81958
feat(agentflow): take redux-color and neo as its own defaults
knsv Sep 1, 2026
fef7026
fix(agentflow): container slots follow declaration order, and match t…
knsv Sep 1, 2026
828ed45
docs: document the per-diagram defaults, and make the docs site show …
ashishjain0512 Sep 1, 2026
44f6596
docs: show each diagram type drawn both ways
ashishjain0512 Sep 1, 2026
f80372c
Merge pull request #8197 from mermaid-js/fix/agentflow-redux-colors
ashishjain0512 Sep 1, 2026
cbc686b
docs: address the CodeRabbit and sisyphus-bot review on #8198
ashishjain0512 Sep 1, 2026
bfc034c
Merge remote-tracking branch 'origin/claude/redux-color-default-theme…
ashishjain0512 Sep 1, 2026
1cebd2a
fix(docs): give the usecase docs spec a timeout, and take in agentflow
ashishjain0512 Sep 1, 2026
d227439
Merge pull request #8198 from mermaid-js/claude/per-diagram-appearanc…
pbrolin47 Sep 1, 2026
b42534e
Merge branch 'develop' into claude/redux-color-default-theme
knsv Sep 2, 2026
59c6188
Addressed review comments
pbrolin47 Sep 2, 2026
9103671
docs(usecase): describe how rotate actually numbers its colour slots
knsv Sep 2, 2026
7a80472
Merge pull request #8148 from mermaid-js/claude/redux-color-default-t…
knsv Sep 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/agentflow-redux-colors.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'mermaid': minor
---

feat(agentflow): take the redux colour palette. Under `redux-color` and `redux-dark-color`, every agentflow node kind — tool, task, decision, input, refdoc, connector, action — gets its own colour from a fixed palette slot, so colour says what an element _is_ and stays put when the diagram is edited around it. Containers cycle a counter in declaration order, the way flowchart subgraphs do, from the slots above the kind range so a container frame never matches a node inside it. A collapsed container keeps its slot. `redux-dark-color` carries borders but no fills, so nodes there take palette strokes over the theme's own background. Agentflow also takes `redux-color` and `neo` as its own per-diagram defaults, so an agentflow diagram that sets neither renders with the palette; anything set in front matter, a directive or `initialize()` still wins.
5 changes: 5 additions & 0 deletions .changeset/block-redux-color-palette.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'mermaid': patch
---

fix(block): apply the redux colour palette to composite blocks. Composites now take a per-container colour under `redux-color` and `redux-dark-color`, matching how flowchart subgraphs are coloured — one counter over containers, in declaration order, with the plain shapes left on the flat theme colour. The palette is opt-in: block does not default to `redux-color` the way flowchart and several other diagram types do, so set `theme: redux-color` (or `redux-dark-color`) explicitly to see it. `classDef`/`style` still win.
5 changes: 5 additions & 0 deletions .changeset/dark-theme-drift-and-palette-indexing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'mermaid': patch
---

fix(themes): `redux-dark`, `redux-dark-color` and `neo-dark` shipped `secondBkg` as the literal string `calculated`, so railroad rendered the invalid `fill: calculated`; it is now computed as `theme-dark` does. The same three themes had gantt done-task labels at 1.07:1 contrast — a light fill under their light task ink — now 5.7:1 or better. The ER and requirement stylesheets also validate `look` before interpolating it into a CSS selector.
6 changes: 4 additions & 2 deletions .changeset/er-requirement-palette-css.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@
'mermaid': patch
---

fix(er, requirement, timeline): stop the ER, requirement and timeline stylesheets emitting invalid CSS for the colour themes.
fix(er, requirement, timeline): stop the ER, requirement and timeline stylesheets emitting CSS the browser discards for the colour themes.

All three generate one rule per palette slot, looping to `THEME_COLOR_LIMIT` and indexing the palette by the loop counter. Indexing raw means a palette with fewer entries than that limit emits `stroke: undefined` for the overflow slots; all three now wrap at the palette length, and bail before the loop for an empty palette — wrapping alone is not enough there, because `i % 0` is `NaN` and `[][NaN]` is `undefined`.
All three generate one rule per palette slot. ER and requirement looped to `THEME_COLOR_LIMIT` and indexed the palette by the loop counter, which goes wrong in both directions: a palette shorter than the limit emitted `stroke: undefined` for the overflow slots, and a palette _longer_ than it left entities stamped with a slot that had no rule at all, rendering unstyled beside coloured neighbours. Both now take the loop bound from the palette itself, which is the same length the boxes stamp with — so the rules emitted and the slots stamped cannot disagree. Both also bail before the loop for an empty palette, since wrapping alone is not enough there: `i % 0` is `NaN` and `[][NaN]` is `undefined`.

Timeline keeps looping to `THEME_COLOR_LIMIT` and wrapping, because it numbers `.section-N` classes rather than palette slots — nothing stamps those, so the palette cycles across however many sections exist.

`requirement` also emitted `fill: ;` — a property with no value, which is invalid — whenever there was no background palette. That is the live case for `redux-dark-color`, which ships a border palette and no background palette so that it colours outlines only. The declaration is now omitted instead.

Expand Down
7 changes: 7 additions & 0 deletions .changeset/per-diagram-appearance-defaults.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'mermaid': minor
---

**`theme`, `look` and `layout` can now be set per diagram type**, in each diagram's config section — `mermaid.initialize({ look: 'classic', flowchart: { look: 'handDrawn' } })`, or the same under `config` in front matter. The schema uses the same mechanism to give a diagram type its own default. Resolution, highest first: front matter or directive, `initialize()`, the diagram type's default, the global default; a diagram-scoped value beats a global one set in the same layer.

Swimlanes take `layout: swimlane` from that schema default instead of having it forced by their `init` hook, so `swimlane: { layout: ... }` and a `layout` in front matter are now honoured. An unregistered layout also always falls back to `dagre` with a warning rather than throwing — state diagrams skipped that fallback, and mindmaps threw when `cose-bilkent` was absent, as it is in `@mermaid-js/tiny`.
7 changes: 7 additions & 0 deletions .changeset/redux-color-becomes-default-theme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'mermaid': major
---

**`redux-color` is now the default theme and `neo` the default look for ten diagram types** — flowchart, swimlane, class, ER, requirement, sequence, state, use case, Venn and agentflow. Those rendered without an explicit `theme` and `look` change appearance; every other diagram type keeps `default` and `classic`. To keep the previous appearance, set both explicitly — `mermaid.initialize({ theme: 'default', look: 'classic' })`, or the same two keys under `config` in front matter.

An unrecognised `theme` name now resolves to the default theme in name as well as in variables; previously the invalid name stayed in place while the default's variables were loaded, and every palette-aware stylesheet gates on the name. `theme: 'null'`, the documented way to disable the pre-defined themes, is unaffected. Note that `neo` paints node strokes with a gradient when the theme sets `useGradient`, which `base` does; setting a custom `nodeBorder` on `base` turns the gradient off.
11 changes: 11 additions & 0 deletions .changeset/redux-color-state-composites.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
'mermaid': minor
---

feat(themes): composite states now take a per-container colour under the `redux-color` and `redux-dark-color` themes, as flowchart subgraphs already do. Each composite gets the palette's border colour on its outline and its background tint behind the title strip; nested composites each take the next colour, so depth stays readable. The body keeps the theme's own `compositeBackground`. `redux-dark-color` colours the outlines only, matching how it treats ER, requirement and sequence.

The concurrency regions produced by a `--` divider share the colour of the composite they split, rather than taking one of their own — the author wrote a single composite, so it is drawn as one thing in parts. Adding a `--` therefore leaves every other composite's colour untouched.

Under the `handDrawn` look, concurrency regions are now filled solid rather than hatched, so that they can carry the palette tint the same way every other look does.

States inside a composite stay uniform. A composite carrying its own `classDef` or `style` keeps those colours and takes no palette slot, and neither do its concurrency regions; the slot is still spent, so styling one composite does not shift the colours of the ones after it. Note that this opt-out is all-or-nothing: a `classDef` that sets only text properties, such as `font-weight`, still takes that composite out of the palette.
5 changes: 5 additions & 0 deletions .changeset/redux-color-swimlane-lanes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'mermaid': minor
---

feat(themes): swimlane lanes take a per-lane colour under the `redux-color` and `redux-dark-color` themes, cycling every 12 as flowchart subgraphs do. The lane holding ungrouped nodes takes its own slot and now follows the diagram's `look`.
5 changes: 5 additions & 0 deletions .changeset/redux-color-venn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'mermaid': patch
---

fix(themes): venn circles follow the `redux-color` and `redux-dark-color` palettes. Neither theme defined any `venn*` variable, so every circle rendered in one flat colour.
10 changes: 10 additions & 0 deletions .changeset/sequence-neo-redux-fixes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
'mermaid': patch
---

fix: sequence diagram actors under the `neo` look and `redux` themes. Notes no longer render bold,
a `rect` section band is no longer drawn white on white, and participants follow one vertical
model: every lifeline starts and ends on a shared line, all participant glyphs are one size with
their feet on a common edge, single-line labels share one baseline in the header and in the
mirrored footer, and a multiline label grows away from the lifeline instead of moving it. The
`classic` look is unchanged.
5 changes: 5 additions & 0 deletions .changeset/usecase-role-colors.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'mermaid': minor
---

feat(usecase): use case diagrams now take colour by role — actors, use cases and system boundaries each get their own colour from the new `usecaseActorBkg`/`usecaseActorBorder`, `usecaseBkg`/`usecaseBorder` and `usecaseBoundaryBkg`/`usecaseBoundaryBorder` theme variables, with `usecaseIncludeLine`/`usecaseExtendLine` separating the two dashed relationship kinds by hue. `redux-color` and `redux-dark-color` set them; every other theme is unchanged. Colour is keyed to the kind of element, so editing a diagram never recolours the elements around the edit. Set `usecase.colorScheme: 'rotate'` for the per-element palette cycle instead, and `classDef`/`style` still wins over both.
13 changes: 11 additions & 2 deletions .esbuild/dev-explorer/diagram-viewer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,12 @@
| 'forest'
| 'neutral'
| 'base'
| 'neo'
| 'neo-dark'
| 'redux'
| 'redux-dark'
| 'redux-color';
| 'redux-color'
| 'redux-dark-color';
type MermaidLayout = 'dagre' | 'elk' | 'domus' | 'hola' | 'swimlane';
type MermaidLook = 'classic' | 'handDrawn' | 'neo';
type MermaidLogLevel = 'trace' | 'debug' | 'info' | 'warn' | 'error' | 'fatal';
Expand Down Expand Up @@ -292,9 +295,12 @@
v === 'forest' ||
v === 'neutral' ||
v === 'base' ||
v === 'neo' ||
v === 'neo-dark' ||
v === 'redux' ||
v === 'redux-dark' ||
v === 'redux-color'
v === 'redux-color' ||
v === 'redux-dark-color'
);
}

Expand Down Expand Up @@ -620,14 +626,14 @@
this.activeTab = tab;
if (tab === 'code') {
void this.updateComplete.then(() => {
const editor = this.querySelector('dev-code-editor') as any;

Check warning on line 629 in .esbuild/dev-explorer/diagram-viewer.ts

View workflow job for this annotation

GitHub Actions / autofix

Unexpected any. Specify a different type
editor?.requestMeasure?.();
});
}
}

#syncConsolePanelFilters() {
const panel = this.querySelector('dev-console-panel') as any;

Check warning on line 636 in .esbuild/dev-explorer/diagram-viewer.ts

View workflow job for this annotation

GitHub Actions / autofix

Unexpected any. Specify a different type
if (!panel) return;
// This is intentionally opinionated: less noise by default as logLevel increases.
if (
Expand All @@ -653,7 +659,7 @@
}

#appendLog(entry: LogEntry) {
const panel = this.querySelector('dev-console-panel') as any;

Check warning on line 662 in .esbuild/dev-explorer/diagram-viewer.ts

View workflow job for this annotation

GitHub Actions / autofix

Unexpected any. Specify a different type
panel?.append?.(entry);
}

Expand Down Expand Up @@ -681,11 +687,11 @@
// Capture those too (map debug/info/log -> panel "info").
console.log = (...args) => {
capture('info', args);
this.#originalConsole!.log.apply(console, args as any);

Check warning on line 690 in .esbuild/dev-explorer/diagram-viewer.ts

View workflow job for this annotation

GitHub Actions / autofix

Unexpected any. Specify a different type
};
console.info = (...args) => {
capture('info', args);
this.#originalConsole!.info.apply(console, args as any);

Check warning on line 694 in .esbuild/dev-explorer/diagram-viewer.ts

View workflow job for this annotation

GitHub Actions / autofix

Unexpected any. Specify a different type
};
console.debug = (...args) => {
capture('info', args);
Expand Down Expand Up @@ -1245,9 +1251,12 @@
<sl-option value="forest">forest</sl-option>
<sl-option value="neutral">neutral</sl-option>
<sl-option value="base">base</sl-option>
<sl-option value="neo">neo</sl-option>
<sl-option value="neo-dark">neo-dark</sl-option>
<sl-option value="redux">redux</sl-option>
<sl-option value="redux-dark">redux-dark</sl-option>
<sl-option value="redux-color">redux-color</sl-option>
<sl-option value="redux-dark-color">redux-dark-color</sl-option>
</sl-select>
</div>

Expand Down
4 changes: 3 additions & 1 deletion .esbuild/dev-explorer/public/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,9 @@ dev-explorer-app .diagram-inner > svg {
}

dev-explorer-app .diagram-inner[data-theme='dark'],
dev-explorer-app .diagram-inner[data-theme='redux-dark'] {
dev-explorer-app .diagram-inner[data-theme='neo-dark'],
dev-explorer-app .diagram-inner[data-theme='redux-dark'],
dev-explorer-app .diagram-inner[data-theme='redux-dark-color'] {
background: #0b1020;
color: #e8eefc;
}
Expand Down
1 change: 1 addition & 0 deletions docs/config/setup/config/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,6 @@
- [sanitize](functions/sanitize.md)
- [saveConfigFromInitialize](functions/saveConfigFromInitialize.md)
- [~~setConfig~~](functions/setConfig.md)
- [setDiagramConfigScope](functions/setDiagramConfigScope.md)
- [setSiteConfig](functions/setSiteConfig.md)
- [updateSiteConfig](functions/updateSiteConfig.md)
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/addDirective.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **addDirective**(`directive`): `void`

Defined in: [packages/mermaid/src/config.ts:173](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L173)
Defined in: [packages/mermaid/src/config.ts:277](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L277)

Pushes in a directive to the configuration

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/evaluate.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **evaluate**(`val?`): `boolean`

Defined in: [packages/mermaid/src/config.ts:16](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L16)
Defined in: [packages/mermaid/src/config.ts:62](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L62)

Converts a string/boolean into a boolean

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/getConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **getConfig**(): [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:120](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L120)
Defined in: [packages/mermaid/src/config.ts:224](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L224)

Returns a copy of the `currentConfig`.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **getEffectiveHtmlLabels**(`config`): `boolean`

Defined in: [packages/mermaid/src/config.ts:246](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L246)
Defined in: [packages/mermaid/src/config.ts:352](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L352)

Helper function to handle deprecated flowchart.htmlLabels

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/getSiteConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **getSiteConfig**(): [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:94](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L94)
Defined in: [packages/mermaid/src/config.ts:198](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L198)

Returns a copy of the current `siteConfig` base configuration.

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/getUserDefinedConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **getUserDefinedConfig**(): [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:227](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L227)
Defined in: [packages/mermaid/src/config.ts:333](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L333)

## Returns

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/reset.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **reset**(`config`): `void`

Defined in: [packages/mermaid/src/config.ts:194](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L194)
Defined in: [packages/mermaid/src/config.ts:298](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L298)

Resets the current config and applied directives to the provided config.

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/sanitize.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **sanitize**(`options`): `void`

Defined in: [packages/mermaid/src/config.ts:131](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L131)
Defined in: [packages/mermaid/src/config.ts:235](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L235)

Ensures options parameter does not attempt to override `siteConfig` secure keys.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **saveConfigFromInitialize**(`conf`): `void`

Defined in: [packages/mermaid/src/config.ts:78](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L78)
Defined in: [packages/mermaid/src/config.ts:181](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L181)

## Parameters

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/setConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **setConfig**(`conf`): [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:106](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L106)
Defined in: [packages/mermaid/src/config.ts:210](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L210)

Updates the `currentConfig` with the provided `conf` after sanitization.

Expand Down
29 changes: 29 additions & 0 deletions docs/config/setup/config/functions/setDiagramConfigScope.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
> **Warning**
>
> ## THIS IS AN AUTOGENERATED FILE. DO NOT EDIT.
>
> ## Please edit the corresponding file in [/packages/mermaid/src/docs/config/setup/config/functions/setDiagramConfigScope.md](../../../../../packages/mermaid/src/docs/config/setup/config/functions/setDiagramConfigScope.md).

[**mermaid**](../../README.md)

---

# Function: setDiagramConfigScope()

> **setDiagramConfigScope**(`diagramType?`): `void`

Defined in: [packages/mermaid/src/config.ts:150](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L150)

Names the diagram type being parsed or rendered, so its own appearance defaults apply.

## Parameters

### diagramType?

`string`

The type `detectType` returned, e.g. `flowchart-v2`; `undefined` to leave scope.

## Returns

`void`
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/setSiteConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **setSiteConfig**(`conf`): [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:64](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L64)
Defined in: [packages/mermaid/src/config.ts:164](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L164)

Sets the `siteConfig` to the desired values.

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/functions/updateSiteConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

> **updateSiteConfig**(`conf`): [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:82](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L82)
Defined in: [packages/mermaid/src/config.ts:185](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L185)

## Parameters

Expand Down
2 changes: 1 addition & 1 deletion docs/config/setup/config/variables/defaultConfig.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@

> `const` **defaultConfig**: [`MermaidConfig`](../../mermaid/interfaces/MermaidConfig.md)

Defined in: [packages/mermaid/src/config.ts:8](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L8)
Defined in: [packages/mermaid/src/config.ts:9](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/config.ts#L9)
2 changes: 1 addition & 1 deletion docs/config/setup/defaultConfig/variables/configKeys.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@

> `const` **configKeys**: `Set`<`string`>

Defined in: [packages/mermaid/src/defaultConfig.ts:354](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/defaultConfig.ts#L354)
Defined in: [packages/mermaid/src/defaultConfig.ts:358](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/defaultConfig.ts#L358)
10 changes: 4 additions & 6 deletions docs/config/setup/mermaid/interfaces/Mermaid.md
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,10 @@ Defined in: [packages/mermaid/src/mermaid.ts:466](https://github.com/mermaid-js/

Defined in: [packages/mermaid/src/mermaid.ts:460](https://github.com/mermaid-js/mermaid/blob/master/packages/mermaid/src/mermaid.ts#L460)

Renders the diagram, holding the diagram config scope for exactly as long as the render.
Leaving it set would make `getConfig()` report the last diagram's appearance as the
global answer for every caller between renders.

#### Parameters

##### id
Expand All @@ -362,12 +366,6 @@ Defined in: [packages/mermaid/src/mermaid.ts:460](https://github.com/mermaid-js/

`Promise`<[`RenderResult`](RenderResult.md)>

#### Deprecated

- use the `mermaid.render` function instead of `mermaid.mermaidAPI.render`

Deprecated for external use.

---

### run()
Expand Down
Loading
Loading