Compare commits

..

1432 Commits

Author SHA1 Message Date
Sidharth Vinod
13d72262d9 Merge pull request #6847 from mermaid-js/rajat-ht/feat-editor-selection-ab-test
Feat: Add editor selection A/B test
2025-08-13 21:55:18 +05:30
rajat-ht
62dee0bad4 chore: update UI for variant A 2025-08-13 21:51:21 +05:30
rajat-ht
9e81e1146a chore: spell check 2025-08-13 19:34:48 +05:30
rajat-ht
186429ae32 chore: Update UI design 2025-08-13 16:28:18 +05:30
rajat-ht
2a514fa69e Feat: Add editor selection A/B test 2025-08-12 18:18:03 +05:30
Sidharth Vinod
bcd3e33243 Merge pull request #6776 from mermaid-js/update-blog
DOCS: update blog page
2025-07-18 13:52:59 +05:30
Steph
b2754bc553 update blog page 2025-07-17 14:44:38 -07:00
Sidharth Vinod
b65a73f432 Merge pull request #6697 from mermaid-js/rajat-ht/feat-add-start-pro-trial
feat: Add start pro trial button.
2025-07-17 11:57:18 +05:30
Ashish Jain
95733b6295 Merge pull request #6762 from mermaid-js/changeset-release/master
Version Packages
2025-07-16 14:05:42 +02:00
github-actions[bot]
767754f4fb Version Packages 2025-07-16 08:25:22 +00:00
Ashish Jain
cff59c58b4 Merge pull request #6757 from mermaid-js/develop
Pre Release
2025-07-16 10:23:12 +02:00
Sidharth Vinod
5b241bbb97 Merge pull request #6758 from mermaid-js/fix/certificate-error-for-noteshub
add noteshub.app to exclusions for certificate errors
2025-07-15 21:43:32 +05:30
shubham-mermaid
7e5e47843b add noteshub.app to exclusions for certificate errors
on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com>
2025-07-15 21:36:22 +05:30
Sidharth Vinod
9e2cd1a926 Merge pull request #6738 from mermaid-js/treemap-diagram-to-use-the-new-class-based-approach
Updated code to use class based approach for treemap
2025-07-15 14:43:24 +00:00
Sidharth Vinod
abf2227faf Merge pull request #6751 from mermaid-js/6750-convert-mindmap-to-class-based-approach
6750: Change MindmapDB to class based architecture
2025-07-15 14:40:29 +00:00
Sidharth Vinod
7db942b0e1 Merge pull request #6756 from mzner/chore/update-katex-to-latest-version
chore: update katex to latest version due to CVE vulnerability
2025-07-15 14:36:33 +00:00
Matteo
70041c806f chore: update katex to latest version due to CVE vulnerability 2025-07-15 14:59:14 +02:00
shubham-mermaid
77e2703f72 Merge branch 'develop' into treemap-diagram-to-use-the-new-class-based-approach 2025-07-15 17:41:20 +05:30
shubham-mermaid
771801b366 Updated changeset
on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com>
2025-07-15 17:40:59 +05:30
darshanr0107
a9a0a9b2de Merge branch '6750-convert-mindmap-to-class-based-approach' of https://github.com/mermaid-js/mermaid into 6750-convert-mindmap-to-class-based-approach 2025-07-15 16:51:10 +05:30
darshanr0107
1e5e835c41 updated changeset on-behalf-of: @Mermaid-Chart hello@mermaidchart.com 2025-07-15 16:50:15 +05:30
Sidharth Vinod
1f3f8da0f7 Merge pull request #6749 from mermaid-js/chore/downgrade-chokidar-to-3.6.0
chore: downgrade chokidar to 3.6.0
2025-07-15 16:40:56 +05:30
Sidharth Vinod
b11f40e8ce Merge branch 'develop' into chore/downgrade-chokidar-to-3.6.0
* develop:
  chore: Update jsdom
  Update @argos-ci/cypress to v5.0.2
  Update @argos-ci/cypress to v5.0.1
  chore: Upgrade cypress
  chore: Update @argos-ci/cypress to v5
  chore(test): Finish refactoring of jsdomit tests
  docs(tests): Documentation for `jsdomIt` tests
  test(refactor): Provide SVG selection in `jsdomIt` function
  test(refactor): Use real-ish rendering instead of heavy mocking in unit tests
2025-07-15 16:40:18 +05:30
Sidharth Vinod
1fe045e638 chore: pin chokidar version 2025-07-15 16:36:13 +05:30
Sidharth Vinod
1c750ffc70 Merge pull request #6675 from quilicicf/chore/6627_improve-rendering-tests
Improve unit tests to allow pseudo-render tests
2025-07-15 09:57:48 +00:00
Sidharth Vinod
b0ec93f29c chore: Update jsdom 2025-07-15 13:54:45 +05:30
shubham-mermaid
6b071c135a Merge branch 'develop' into 6750-convert-mindmap-to-class-based-approach 2025-07-15 13:49:35 +05:30
shubham-mermaid
42a3c3487f Remove constructor and clear method call from TreeMapDB class
on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com>
2025-07-15 13:44:26 +05:30
Sidharth Vinod
d7b8ed2c5a Merge remote-tracking branch 'origin/develop' into pr/quilicicf/6675
* origin/develop:
  Update @argos-ci/cypress to v5.0.2
  Update @argos-ci/cypress to v5.0.1
  chore: Upgrade cypress
  chore: Update @argos-ci/cypress to v5
2025-07-15 13:34:11 +05:30
darshanr0107
96c21c7e54 resolve PR comments and update changeset 2025-07-15 12:19:02 +05:30
shubham-mermaid
e95e4d155a Updated changeset on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com> 2025-07-15 12:09:17 +05:30
shubham-mermaid
688170558c Updated changeset on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com> 2025-07-15 12:07:52 +05:30
shubham-mermaid
832f012e10 Merge branch 'treemap-diagram-to-use-the-new-class-based-approach' of https://github.com/mermaid-js/mermaid into treemap-diagram-to-use-the-new-class-based-approach 2025-07-15 12:07:01 +05:30
shubham-mermaid
2e2e8c4152 Added clear function in constructor on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com> 2025-07-15 12:06:22 +05:30
Sidharth Vinod
6ff6e08c4b Merge branch 'develop' into treemap-diagram-to-use-the-new-class-based-approach 2025-07-15 00:00:49 +05:30
Sidharth Vinod
d7f1f12549 Merge pull request #6748 from mermaid-js/sidv/updateArgosCy
chore: Update @argos-ci/cypress to v5
2025-07-14 23:35:38 +05:30
Sidharth Vinod
6e56869566 Update @argos-ci/cypress to v5.0.2 2025-07-14 23:22:40 +05:30
darshanr0107
d3e2be35be added changeset 2025-07-14 20:12:31 +05:30
Sidharth Vinod
852cb35f0a Update @argos-ci/cypress to v5.0.1 2025-07-14 20:05:57 +05:30
darshanr0107
260a045da0 migrate mindmap to class based approach 2025-07-14 20:00:13 +05:30
omkarht
a28965064d chore: downgrade chokidar to 3.6.0 2025-07-14 19:34:02 +05:30
Sidharth Vinod
355eeeb9cc chore: Upgrade cypress 2025-07-14 18:33:09 +05:30
Sidharth Vinod
5449d6a447 chore: Update @argos-ci/cypress to v5
This fixes the random test renaming issue
2025-07-14 18:15:18 +05:30
quilicicf
34e91f8b65 chore(test): Finish refactoring of jsdomit tests 2025-07-14 14:04:53 +02:00
quilicicf
627ee1f34d docs(tests): Documentation for jsdomIt tests 2025-07-14 14:04:53 +02:00
quilicicf
28840ebd84 test(refactor): Provide SVG selection in jsdomIt function 2025-07-14 14:04:53 +02:00
quilicicf
4145879003 test(refactor): Use real-ish rendering instead of heavy mocking in unit tests
* Creates a utility method `jsdomIt` that overrides `it` from `vitest` and fakes a browser environment by :
  * Creating a DOM with `jsdom` (and `canvas`)
  * Adding (for the duration of the test) that DOM's `window` and `document` on `global`
  * Monkey-patching DOM methods that require a rendering engine (`Element.getBBox` & `Element.getComputedLength`)
* Removes all d3 mocking since it can now work normally in `jsdomIt` tests
* Re-writes existing rendering tests to :
  * Use `jsdomIt`
  * Get rid of most of the involved mocking
  * Run `expect` calls on the generated SVG instead

Inspired by d3's own test code mocking : https://github.com/d3/d3-selection/blob/v3.0.0/test/jsdom.js
2025-07-14 14:04:52 +02:00
shubham-mermaid
e097b480d5 Merge branch 'develop' into treemap-diagram-to-use-the-new-class-based-approach 2025-07-14 16:12:37 +05:30
shubham-mermaid
f76e27db70 Merge pull request #6747 from mermaid-js/6619-sequence-title-box-safari
6619: Prevent title from overlapping with box top border in Safari
2025-07-14 09:13:53 +00:00
darshanr0107
3e3ae08930 add changeset 2025-07-14 14:17:00 +05:30
darshanr0107
966c112eb1 prevent title from overlapping with box top border in Safari 2025-07-14 14:11:06 +05:30
shubham-mermaid
55527e70c2 Merge pull request #6745 from mermaid-js/renovate/autofix-ci-action-digest
chore(deps): update autofix-ci/action digest to 635ffb0
2025-07-14 06:47:45 +00:00
renovate[bot]
447d1cf988 chore(deps): update autofix-ci/action digest to 635ffb0 2025-07-14 00:55:26 +00:00
shubham-mermaid
12e3d31437 Addresses type incompatibility by setting the parser database to undefined, on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com> 2025-07-11 16:54:56 +05:30
shubham-mermaid
ad024b01d6 Updated the function to use class method on-behalf-of: @Mermaid-Chart <hello@mermaidchart.com> 2025-07-11 15:18:41 +05:30
shubham-mermaid
c12aea588c Updated code as per suggestions on-behalf-of: @MermaidChart <hello@mermaidchart.com> 2025-07-11 15:16:49 +05:30
shubham-mermaid
9dfbf1166d Refactors treemap DB to class-based state management on-behalf-of: @MermaidChart shubham-mermaid@mermaidchart.com 2025-07-11 14:04:30 +05:30
shubham-mermaid
d90634bf2b added changeset 2025-07-10 20:39:52 +05:30
shubham-mermaid
90707e8062 fix(parser): initialize parser.yy as TreemapDB 2025-07-10 20:25:46 +05:30
shubham-mermaid
7e23f984e6 Updated code to use class based approach 2025-07-10 20:21:27 +05:30
Alois Klink
fad6676d18 Merge pull request #6715 from Syn3ugar/feature/timelineRenderer-conf
fix: update leftMargin value
2025-07-10 10:37:48 +00:00
Syn3ugar
637680d4d9 fix(timeline): load leftMargin from config
The `timeline.leftMargin` value in the docs/schema was not being
correctly loaded for timeline diagrams.
2025-07-10 18:28:15 +08:00
shubham-mermaid
5f6f5110fd Merge pull request #6718 from MoonBall/feat/modify-blockDiagram-log
Modify block diagram's logger to global log
2025-07-10 08:00:39 +00:00
Sidharth Vinod
af47269342 Merge pull request #6615 from mermaid-js/renovate/major-all-major
fix(deps): update all major dependencies (major)
2025-07-09 20:05:52 +00:00
renovate[bot]
d3c0893937 fix(deps): update all major dependencies 2025-07-09 19:53:14 +00:00
Sidharth Vinod
75ef9bc681 fix: Make PR labeler stricter 2025-07-10 01:21:42 +05:30
Sidharth Vinod
45edc91591 Merge pull request #6510 from mermaid-js/sidv/packet-release
Move `packet` diagram out of beta
2025-07-09 19:35:19 +00:00
Sidharth Vinod
f4edd19371 chore: Add auto labeler for Sponsored work 2025-07-10 01:00:10 +05:30
Sidharth Vinod
b611a13e04 chore: Add test for packet-beta 2025-07-10 00:44:07 +05:30
Sidharth Vinod
7a38eb715d chore: Changeset 2025-07-10 00:43:02 +05:30
Sidharth Vinod
2715ddb338 chore: Update packet-beta to packet 2025-07-10 00:41:02 +05:30
Sidharth Vinod
ca2eca58c9 Merge branch 'develop' into sidv/packet-release
* develop: (266 commits)
  chore: update E2E timings
  docs: Update changeset
  fix: Add useful error message to test
  chore: Add treemap example
  chore: Add treemap example
  chore: Add peerDependency to @mermaid-js/examples
  Version Packages
  docs: Update changeset
  update in changeset
  updated validaor and tests to use treemap
  Updated parser to use treemap
  chore: Fail build in CI on type errors
  fix text going outside node
  Version Packages
  Updated phpbb url  to support 403 in lychee
  Updated lychee for working url phpbb.com
  resolve PR comment
  resolve PR comments
  chore: update E2E timings
  add changeset
  ...
2025-07-10 00:38:41 +05:30
shubham-mermaid
b4fae2d096 Merge pull request #6716 from mermaid-js/6664-text-going-outside-node
6664: Text rendering issue in flowchart note elements
2025-07-09 13:18:26 +00:00
shubham-mermaid
6dd9af0dd4 Merge branch 'develop' into 6664-text-going-outside-node 2025-07-09 18:34:15 +05:30
shubham-mermaid
3151241559 Merge branch 'develop' into feat/modify-blockDiagram-log 2025-07-09 13:47:24 +05:30
Sidharth Vinod
dda9c9b46e Merge pull request #6731 from mermaid-js/update-timings
Update E2E Timings
2025-07-08 13:23:06 +05:30
github-actions[bot]
cdd1a70b67 chore: update E2E timings 2025-07-08 04:14:48 +00:00
Sidharth Vinod
12c94a177b Merge pull request #6728 from mermaid-js/develop
Pre Release
2025-07-08 01:12:32 +05:30
Sidharth Vinod
d8bd4dea93 Merge pull request #6453 from mermaid-js/sidv/examples
Add metadata for diagrams
2025-07-08 01:11:26 +05:30
Sidharth Vinod
6deb476182 docs: Update changeset 2025-07-08 01:01:47 +05:30
Sidharth Vinod
ed297ee235 fix: Add useful error message to test 2025-07-08 00:55:44 +05:30
Sidharth Vinod
03c1201fcb chore: Add treemap example 2025-07-08 00:55:24 +05:30
Sidharth Vinod
3ca317c5a0 chore: Add treemap example 2025-07-08 00:45:47 +05:30
Sidharth Vinod
4d83263388 chore: Add peerDependency to @mermaid-js/examples
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-07-08 00:44:07 +05:30
Sidharth Vinod
254e5cbd51 Merge branch 'sidv/examples' of https://github.com/mermaid-js/mermaid into sidv/examples
* 'sidv/examples' of https://github.com/mermaid-js/mermaid:
2025-07-08 00:39:56 +05:30
Sidharth Vinod
a58dd3c6ce Merge branch 'develop' into sidv/examples 2025-07-08 00:38:03 +05:30
Sidharth Vinod
10b7bb568f Merge branch 'develop' into sidv/examples
* develop: (198 commits)
  Version Packages
  docs: Update changeset
  update in changeset
  updated validaor and tests to use treemap
  Updated parser to use treemap
  chore: Fail build in CI on type errors
  Version Packages
  Updated phpbb url  to support 403 in lychee
  Updated lychee for working url phpbb.com
  resolve PR comment
  resolve PR comments
  chore: update E2E timings
  add changeset
  log warning when duplicate commit IDs are encountered
  Added updated chatgpt  plugin url and removed failing url
  Added classes and outernodes in imperativestate
  Updated code as per suggestions
  fixed unwanted vitepress from lockfile
  Updated as per suggestions
  Added step to install pnpm and echo statements for debugging.
  ...
2025-07-08 00:36:08 +05:30
Sidharth Vinod
1aa2870224 Merge pull request #6727 from mermaid-js/changeset-release/master
Version Packages
2025-07-07 20:52:47 +05:30
github-actions[bot]
8fbcbb6dc9 Version Packages 2025-07-07 15:21:07 +00:00
Sidharth Vinod
3e545d7925 docs: Update changeset 2025-07-07 20:49:04 +05:30
Sidharth Vinod
75d2a259ed Merge pull request #6726 from mermaid-js/develop
Pre Release
2025-07-07 20:29:25 +05:30
shubham-mermaid
746280b3e2 Merge pull request #6724 from mermaid-js/sidv/failOnTypeError
chore: Fail build in CI on type errors
2025-07-07 14:08:28 +00:00
Sidharth Vinod
fa4e30bb15 Merge pull request #6725 from mermaid-js/use-treemap-in-languim
Use treemap in languim
2025-07-07 19:23:03 +05:30
shubham-mermaid
950b107dd4 update in changeset 2025-07-07 19:15:50 +05:30
shubham-mermaid
35b84761a9 updated validaor and tests to use treemap 2025-07-07 18:54:38 +05:30
shubham-mermaid
0da2922ee7 Updated parser to use treemap 2025-07-07 18:50:53 +05:30
Sidharth Vinod
85eba01663 chore: Fail build in CI on type errors 2025-07-07 18:02:23 +05:30
rajat-ht
ea72740d1f Merge branch 'master' of https://github.com/mermaid-js/mermaid into rajat-ht/feat-add-start-pro-trial 2025-07-07 17:08:17 +05:30
Gang Chen
79ba50216a Modify block diagram's logger to global log 2025-07-06 01:09:36 +08:00
darshanr0107
9655d07adf fix text going outside node 2025-07-04 16:11:30 +05:30
Ashish Jain
2b3cb6a362 Merge pull request #6713 from mermaid-js/changeset-release/master
Version Packages
2025-07-03 15:51:36 +02:00
rajat-ht
427dc38857 chore: revert 'Open Editor' link in header 2025-07-03 19:21:24 +05:30
rajat-ht
ec21042c53 chore: minor UI updates and added search params to URL 2025-07-03 19:00:33 +05:30
github-actions[bot]
89ac2932c4 Version Packages 2025-07-03 13:28:11 +00:00
Ashish Jain
e828609749 Merge pull request #6695 from mermaid-js/develop
Pre-Release
2025-07-03 15:24:36 +02:00
Ashish Jain
91f141f772 Merge pull request #6711 from mermaid-js/update-lychee-for-phpbb
Updated phpbb url  to support 403 in lychee
2025-07-03 12:53:41 +00:00
shubham-mermaid
c77b968f1e Updated phpbb url to support 403 in lychee 2025-07-03 18:12:12 +05:30
Ashish Jain
ba13981905 Updated lychee for working url phpbb.com 2025-07-03 12:56:09 +02:00
Alois Klink
a7a94b95e1 Merge pull request #6707 from mermaid-js/4838-gitgraph-chronology-duplicate-id
4838: Log warning for duplicate commit IDs in gitGraph
2025-07-03 10:34:25 +00:00
darshanr0107
31f141c61a Merge branch 'develop' into 4838-gitgraph-chronology-duplicate-id 2025-07-03 15:39:40 +05:30
darshanr0107
fb017bebfd resolve PR comment
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-07-03 15:39:26 +05:30
darshanr0107
648698a43a resolve PR comments 2025-07-03 13:57:36 +05:30
Sidharth Vinod
a5e4729c76 Merge pull request #6700 from mermaid-js/update-timings
Update E2E Timings
2025-07-03 12:52:12 +05:30
github-actions[bot]
c884def5fc chore: update E2E timings 2025-07-03 04:14:58 +00:00
rajat-ht
4a86b68e01 chore: update UI as per suggestion 2025-07-02 18:51:06 +05:30
darshanr0107
592c5bb880 add changeset 2025-07-02 12:16:17 +05:30
darshanr0107
da0c6c6c32 log warning when duplicate commit IDs are encountered 2025-07-02 11:59:20 +05:30
Knut Sveidqvist
d9396eedd6 Merge pull request #6698 from mermaid-js/update-urls-in-docs
Added updated chatgpt  plugin url and removed failing url
2025-06-27 12:46:28 +00:00
shubham-mermaid
5f9601b6a8 Merge branch 'develop' into update-urls-in-docs 2025-06-27 17:53:04 +05:30
shubham-mermaid
378f8ece0c Added updated chatgpt plugin url and removed failing url 2025-06-27 17:50:45 +05:30
rajat-ht
8693be56ee feat: Add start pro trial button. 2025-06-27 17:26:54 +05:30
shubham-mermaid
148a42a31a Merge pull request #6590 from mermaid-js/knsv-treemap
Adding support for the new diagram type nested treemap
2025-06-27 10:31:32 +00:00
shubham-mermaid
8980ca4526 Added classes and outernodes in imperativestate 2025-06-27 15:18:53 +05:30
shubham-mermaid
caa04aad8b Updated code as per suggestions 2025-06-27 13:48:44 +05:30
shubham-mermaid
3dc06ea9bd fixed unwanted vitepress from lockfile 2025-06-26 19:27:40 +05:30
shubham-mermaid
c311c1ba5d Merge branch 'develop' into knsv-treemap 2025-06-26 18:40:43 +05:30
Sidharth Vinod
11a86d9c06 Merge pull request #6689 from mermaid-js/#6669-pnpm-lock-workflow-validation-
Added step to install pnpm
2025-06-26 12:59:17 +00:00
shubham-mermaid
037bec189c Updated as per suggestions 2025-06-26 17:43:06 +05:30
shubham-mermaid
9b164dd185 Added step to install pnpm and echo statements for debugging. 2025-06-26 14:41:03 +05:30
shubham-mermaid
4ee124bf91 Merge branch 'develop' into knsv-treemap 2025-06-26 13:04:47 +05:30
Sidharth Vinod
e7970c66ee Merge pull request #6670 from mermaid-js/#6669-pnpm-lock-validations
Added workflow file for validating pnpm-lock file
2025-06-23 09:11:05 +00:00
shubham-mermaid
c7b96be683 Merge branch 'develop' into #6669-pnpm-lock-validations 2025-06-23 12:43:35 +05:30
shubham-mermaid
0623a87d70 Removed js file check in paths 2025-06-23 12:43:13 +05:30
shubham-mermaid
c5f89eaa9a Update .github/workflows/validate-lockfile.yml
Co-authored-by: Sidharth Vinod <github@sidharth.dev>
2025-06-23 12:41:21 +05:30
Sidharth Vinod
1fbe550285 Merge pull request #6659 from sametcn99/patch-1
Add vitepress plugin link
2025-06-21 05:46:08 +00:00
Sidharth Vinod
b3724f04c4 Merge pull request #6673 from mermaid-js/kill-the-bird
Kill the bird
2025-06-21 05:41:04 +00:00
Nacho Orlandoni
2f58a0e188 Kill the bird
This seems like an abandoned product, where the author went on a rampage trying to get it included into as many repositories as he can as a publicity stunt and no longer even works...
2025-06-20 22:07:14 -04:00
shubham-mermaid
6f1e0e4d17 Updated message 2025-06-20 18:57:22 +05:30
shubham-mermaid
7dd8ddc3eb Added generic message. 2025-06-20 18:55:45 +05:30
shubham-mermaid
222d7170f7 Added changeset 2025-06-20 14:11:26 +05:30
shubham-mermaid
3137cff4a5 Added auto-comment 2025-06-20 14:07:37 +05:30
shubham-mermaid
b45b1d7795 Trigger Build 2025-06-20 13:54:18 +05:30
shubham-mermaid
e1030b186e Added validation for packages/mermaid/src/vitepress path 2025-06-20 13:18:50 +05:30
shubham-mermaid
334c8c2962 use depth 0 2025-06-20 13:12:56 +05:30
shubham-mermaid
bdaa3f693a Added PR based sha 2025-06-20 13:11:33 +05:30
shubham-mermaid
be13fb0391 Updated origin to event.pull_request.base.ref 2025-06-20 12:53:47 +05:30
shubham-mermaid
c120901744 Added workflow file for validating pnpm-lock file 2025-06-20 12:47:17 +05:30
Sidharth Vinod
1f07a781e4 Merge pull request #6660 from mermaid-js/changeset-release/master
Version Packages
2025-06-20 10:32:20 +05:30
github-actions[bot]
3132387ede Version Packages 2025-06-19 12:43:20 +00:00
Sidharth Vinod
f41b4c96f9 Update bitter-colts-remain.md 2025-06-19 18:11:16 +05:30
Sidharth Vinod
26bd456c01 chore: Revert manual version upgrade 2025-06-19 13:59:46 +05:30
Sidharth Vinod
8ef7040a8d chore: Update changeset 2025-06-19 13:55:00 +05:30
autofix-ci[bot]
badb019d38 [autofix.ci] apply automated fixes 2025-06-17 11:17:51 +00:00
Sidharth Vinod
e7ec8ed527 fix: Copy changelog to tiny 2025-06-17 16:35:46 +05:30
samet
d85a393bcd Add vitepress plugin link 2025-06-17 14:04:55 +03:00
Sidharth Vinod
7c1e655675 chore: Update changeset to minor bump 2025-06-17 16:34:31 +05:30
Sidharth Vinod
df2ccaa14b Merge pull request #6658 from mermaid-js/develop
Pre-Release
2025-06-17 16:13:14 +05:30
Sidharth Vinod
797ba43d6e chore: lychee ignore mermaid-preview 2025-06-17 16:05:45 +05:30
Sidharth Vinod
d628a971ef Merge branch 'master' into develop
* master: (46 commits)
  Add canonicals to pages migrated to docs.mermaidchart.com
  chore: minor update
  chore: dynamically change text size depending on route
  chore: update text size to lg
  chore: remove tooltip
  chore: update as per PR comment
  chore: Update banner ad
  chore: Use mermaid.live as fallback links in button
  chore: Tweak shadows
  chore : fix UI
  chore: Update URL
  chore: UI refactor
  chore: Update UI design
  chore: removed index and used flag
  chore: code refactor
  chore: Update as per PR suggestion.
  chore: add event listener for button.
  Feat: Add editor popup modal
  Skip foswiki link check
  feat: Pause animation when hovering
  ...
2025-06-17 15:53:29 +05:30
shubham-mermaid
8049b6aef8 Merge pull request #6616 from mermaid-js/fix/timeline-vertical-lines-6610
fix(timeline): ensure consistent vertical line lengths with visible arrowheads
2025-06-17 10:05:42 +00:00
shubham-mermaid
84802118be Merge branch 'develop' into fix/timeline-vertical-lines-6610 2025-06-17 15:18:44 +05:30
shubham-mermaid
e2ef425245 Merge branch 'develop' into fix/timeline-vertical-lines-6610 2025-06-17 14:48:24 +05:30
shubham-mermaid
da98732961 Sync with develop for pnpm-lock 2025-06-17 14:43:13 +05:30
shubham-mermaid
efa11a7325 Merge pull request #6648 from mermaid-js/6647-handle-node-order-elk
#6647 Make elk respect the order of nodes based from the code
2025-06-17 09:08:31 +00:00
Ashish Jain
e5f6ea0b13 Add canonicals to pages migrated to docs.mermaidchart.com 2025-06-17 10:16:46 +02:00
Sidharth Vinod
9562a769db Merge pull request #6624 from mermaid-js/rajat-ht/chore-update-banner-ad
chore: update banner ad
2025-06-16 11:09:18 +05:30
rajat-ht
5cfda33d04 chore: minor update 2025-06-13 22:57:21 +05:30
Knut Sveidqvist
e682172823 Reverting the elk.layered.wrapping.validify.strategy setting 2025-06-11 17:06:17 +02:00
Knut Sveidqvist
85c5b9b4c0 #6647 Make elk respect the order of nodes based from the code 2025-06-11 17:00:29 +02:00
rajat-ht
1e68ed9cc1 chore: dynamically change text size depending on route 2025-05-30 22:50:55 +05:30
rajat-ht
1337c60784 chore: update text size to lg 2025-05-29 22:34:40 +05:30
rajat-ht
a12d1f731a chore: remove tooltip 2025-05-29 17:16:19 +05:30
rajat-ht
b6ba9b79df chore: update as per PR comment 2025-05-29 17:06:25 +05:30
rajat-ht
ce227b5519 chore: Update banner ad 2025-05-29 16:22:20 +05:30
Sidharth Vinod
8a703bd09f Merge pull request #6600 from kimulaco/docs/6599_fix-preview-error
docs: fix preview errors in the flowchart documentation
2025-05-28 22:22:22 +05:30
Sidharth Vinod
c4de3cdc57 Merge pull request #6609 from mermaid-js/rajat-ht/feat-add-editor-popup-modal
Feat: Add editor popup modal
2025-05-28 21:54:21 +05:30
Sidharth Vinod
ef449a601b chore: Use mermaid.live as fallback links in button 2025-05-28 21:53:24 +05:30
Sidharth Vinod
8e84a1a8af chore: Tweak shadows 2025-05-28 21:47:21 +05:30
rajat-ht
a3552e7936 chore : fix UI 2025-05-28 21:27:55 +05:30
rajat-ht
646cdf0d32 chore: Update URL 2025-05-28 02:32:32 +05:30
rajat-ht
99048bfa01 chore: UI refactor 2025-05-27 18:34:32 +05:30
Ashish Jain
ca80f719ea fix(timeline): ensure consistent vertical line lengths with visible arrowheads
- Fixed inconsistent vertical line lengths in timeline diagrams
- All vertical lines now extend to same depth regardless of event count
- Added sufficient padding for clear visibility of dashed lines and arrowheads
- Added comprehensive test case and demo example

Fixes #6610
2025-05-26 12:16:58 +02:00
rajat-ht
0cabc6e8ed chore: Update UI design 2025-05-23 22:14:18 +05:30
rajat-ht
5fe0f53179 chore: removed index and used flag 2025-05-23 16:53:06 +05:30
rajat-ht
e2e3cd2bbd chore: code refactor 2025-05-23 16:30:59 +05:30
rajat-ht
ffb9016d65 Merge branch 'master' of https://github.com/mermaid-js/mermaid into rajat-ht/feat-add-editor-popup-modal 2025-05-23 15:55:04 +05:30
rajat-ht
3c03f289b4 chore: Update as per PR suggestion. 2025-05-23 15:49:12 +05:30
Sidharth Vinod
c6035936b6 Merge pull request #6594 from mermaid-js/rajat-ht/chore-update-tooltip
Chore: Update tooltip
2025-05-22 12:35:56 +05:30
Sidharth Vinod
818699f347 Merge pull request #6595 from yoshinorin/patch-1
docs: fix Markdown links on the `Questions or Suggestions` page
2025-05-22 12:34:14 +05:30
rajat-ht
f23a26e528 chore: add event listener for button. 2025-05-21 17:11:29 +05:30
rajat-ht
48e6e60753 Feat: Add editor popup modal 2025-05-20 20:00:30 +05:30
Knut Sveidqvist
dc3ed65c18 Commented out skipped tests 2025-05-20 15:26:27 +02:00
Knut Sveidqvist
43092e6e11 Fixed rendering issues found while testing, setting to treemap-beta 2025-05-20 15:22:49 +02:00
Knut Sveidqvist
878e77acab Updates after review comments 2025-05-20 12:56:31 +02:00
Sidharth Vinod
2372cd7b21 Skip foswiki link check 2025-05-20 15:31:12 +05:30
Sidharth Vinod
51f0cb2892 feat: Pause animation when hovering 2025-05-20 15:17:56 +05:30
Sidharth Vinod
14e3d77c75 fix: Specifically hide tooltip, instead of using a very specific selector to show 2025-05-20 15:13:38 +05:30
Sidharth Vinod
875fef691b fix: Use CSS instead of JS to hide/show tooltip 2025-05-20 15:01:39 +05:30
Alois Klink
7075f833d0 Merge pull request #6566 from arpitjain099/develop
fix: escape backslashes before parentheses in URL replacement logic
2025-05-20 06:41:51 +00:00
Sidharth Vinod
d629c5eae5 Merge pull request #6581 from ZenUml/feat/update-zenuml-core-to-3_31_1-rebased
Upgrade @zenuml/core to v3.31.1.
2025-05-19 20:16:38 +05:30
Ashish Jain
80904da253 Merge pull request #6423 from BambioGaming/feature/6314_state-click
Feature: Added support for clickable states using the click directive
2025-05-19 05:56:17 +00:00
kimulaco
e6be1e9202 docs(flowchart): disable image shape preview 2025-05-18 08:45:56 +09:00
kimulaco
6f5d889f19 docs(flowchart): fix the example code of Markdown Strings 2025-05-18 08:36:43 +09:00
Knut Sveidqvist
63827db60d Added padding as configuration 2025-05-15 10:59:47 +02:00
Knut Sveidqvist
41108358f6 Adding support for title and accessibilities 2025-05-15 10:44:46 +02:00
Peng Xiao
ec0786a6fa Merge branch 'develop' into feat/update-zenuml-core-to-3_31_1-rebased 2025-05-14 22:00:31 +10:00
autofix-ci[bot]
2ea6695b4b [autofix.ci] apply automated fixes 2025-05-13 16:16:39 +00:00
yoshinorin
6485d1fbca docs: fix Markdown links on the Questions or Suggestions page 2025-05-14 01:04:29 +09:00
Arpit Jain
d0f1dafd49 Merge branch 'develop' into develop 2025-05-13 22:43:34 +09:00
Ashish Jain
f970fc8bea Merge branch 'develop' into knsv-treemap 2025-05-13 14:39:53 +02:00
Ashish Jain
015afc53d5 Merge pull request #6588 from mermaid-js/omkar/fix-er-diagram-styling
Fix: Apply proper styling for Mermaid ER diagrams
2025-05-13 11:48:18 +00:00
rajat-ht
1f44143936 Chore update tooltip 2025-05-13 15:28:24 +05:30
Knut Sveidqvist
db461a4c6c Updated lockfile 2025-05-12 19:21:25 +02:00
Knut Sveidqvist
fe33d5fb53 Merge remote-tracking branch 'origin/develop' into knsv-treemap 2025-05-12 19:18:04 +02:00
Knut Sveidqvist
64c4d4197b Prettier fix for json file 2025-05-12 18:30:06 +02:00
Knut Sveidqvist
ed7bab76f2 Fixed linting issues in markdown file 2025-05-12 18:27:40 +02:00
Knut Sveidqvist
f338802642 Adding changeset 2025-05-12 18:05:43 +02:00
Knut Sveidqvist
445595f942 Handling longer summaries for sections and lint fixes for the renderer 2025-05-12 17:57:23 +02:00
Knut Sveidqvist
66ce617bea Added support for valueFormat directive - linting 2025-05-12 17:47:00 +02:00
Knut Sveidqvist
3e07a5acff Added support for valueFormat directive 2025-05-12 17:46:19 +02:00
Knut Sveidqvist
df1e739194 Added support for valueFormat directive 2025-05-12 17:40:23 +02:00
Knut Sveidqvist
2def5a0768 Added visual tests 2025-05-12 17:16:29 +02:00
Knut Sveidqvist
2746bccef3 Added rendering and documentation for treemap - linting 2025-05-12 15:54:06 +02:00
Knut Sveidqvist
f0c3dfe3b3 Added rendering and documentation for treemap 2025-05-12 15:47:58 +02:00
Arpit Jain
942ae8dcbc Update text associated with change 2025-05-12 11:14:36 +00:00
Arpit Jain
cadcddd40c update change version to patch 2025-05-12 11:13:04 +00:00
Arpit Jain
bca6ed67c3 Add pnpm message for change 2025-05-12 10:39:42 +00:00
Alois Klink
f20c677982 test(e2e): fix arrowMarkerAbsolute: true test
The `/` and `:` characters in `url()` are now escaped using
`CSS.escape`.

See: e79147dcfc
2025-05-12 12:00:09 +02:00
Alois Klink
e46fd145b2 test(e2e): skip arrowMarkerAbsolute: 'false'
This feature looks like it's been broken for a long time, but something
about the Cypress environment was rewriting the URL to be relative,
causing this test to incorrectly pass.
2025-05-12 11:56:26 +02:00
omkarht
b1cf291273 added changeset 2025-05-12 15:23:35 +05:30
omkarht
cac1779c22 Fix: apply proper styling for Mermaid ER diagrams 2025-05-12 15:14:20 +05:30
autofix-ci[bot]
96bd7de40d [autofix.ci] apply automated fixes 2025-05-10 05:33:28 +00:00
Arpit Jain
82874c6584 Add missing export command 2025-05-10 05:28:44 +00:00
Arpit Jain
e79147dcfc update occurrences with getUrl and use CSS.escape function instead 2025-05-10 05:12:48 +00:00
Arpit Jain
28131bab98 Merge branch 'mermaid-js:develop' into develop 2025-05-10 13:53:52 +09:00
BambioGaming
9d6b9369e6 Merge branch 'develop' into feature/6314_state-click 2025-05-09 13:51:51 +01:00
khalil
80351d9f59 Merge branch 'feature/6314_state-click' of https://github.com/BambioGaming/mermaid into feature/6314_state-click 2025-05-09 13:49:44 +01:00
khalil
7b307f812f fixed merge conflicts 2025-05-09 13:47:45 +01:00
khalil
071df09395 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into feature/6314_state-click 2025-05-09 13:26:26 +01:00
Sidharth Vinod
0d047ccbcc Update mermaid-tiny README.md 2025-05-09 05:04:43 -07:00
Knut Sveidqvist
680d65114c Added class suppoort to the grammar 2025-05-09 13:47:45 +02:00
MrCoder
d463f00160 Update pnpm-lock.yaml to match patchedDependencies configuration 2025-05-09 21:22:58 +10:00
MrCoder
941bc69835 chore: Upgrade @zenuml/core to version 0.3.0 2025-05-09 19:28:13 +10:00
MrCoder
107b6cae87 Upgrade @zenuml/core to v3.31.1.
It fixes the issue https://github.com/mermaid-js/mermaid-cli/issues/584 among other improvements.
2025-05-09 19:20:20 +10:00
Sidharth Vinod
1b044a24fa Merge pull request #4734 from mermaid-js/sidv/tinyMermaid
Add `mermaid.tiny.min.js`. 69.7% size reduction.
2025-05-09 05:27:29 +00:00
Sidharth Vinod
17a156901a Merge pull request #5980 from BryanCrotazGivEnergy/packet-diagram-bit-counts
Feature: Packet diagram can use bit counts - implements #5978
2025-05-09 04:59:53 +00:00
Sidharth Vinod
fa22ed137c Merge branch 'develop' into packet-diagram-bit-counts 2025-05-09 10:21:00 +05:30
Sidharth Vinod
6b886abf39 Merge pull request #6578 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.6 [security]
2025-05-09 01:54:06 +05:30
renovate[bot]
4fd64c5bc0 chore(deps): update dependency vite to v6.1.6 [security] 2025-05-08 19:16:11 +00:00
Sidharth Vinod
7e245f970f Merge pull request #6555 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.6 [security]
2025-05-08 19:02:02 +00:00
Knut Sveidqvist
4f8f929340 adjusted layout and theme support 2025-05-08 16:32:40 +02:00
Knut Sveidqvist
3629e8e480 Update treemap renderer for improved padding and layout adjustments 2025-05-08 14:20:05 +02:00
Knut Sveidqvist
ff48c2e1da adjusted layout WIP 2025-05-08 13:42:50 +02:00
Knut Sveidqvist
1bd13b50f1 added proper hierarchy from parsed data 2025-05-08 11:19:19 +02:00
renovate[bot]
bbe3489b4f chore(deps): update dependency vite to v6.1.6 [security] 2025-05-08 07:32:47 +00:00
Sidharth Vinod
31ba692f65 Merge pull request #6563 from mermaid-js/renovate/peter-evans-create-pull-request-digest
chore(deps): update peter-evans/create-pull-request digest to 889dce9
2025-05-08 07:18:11 +00:00
Sidharth Vinod
b073175fe9 Merge pull request #6564 from mermaid-js/renovate/eslint
chore(deps): update eslint (minor)
2025-05-08 07:13:06 +00:00
renovate[bot]
e2e22de1d9 chore(deps): update eslint 2025-05-07 20:28:30 +00:00
renovate[bot]
c370ebe520 chore(deps): update peter-evans/create-pull-request digest to 889dce9 2025-05-07 20:27:29 +00:00
BambioGaming
d732fa5f86 Update .changeset/public-things-stare.md
Co-authored-by: Ashish Jain <ashishjain0512@gmail.com>
2025-05-07 21:21:56 +01:00
Ashish Jain
ce1bfb2af5 Merge pull request #6470 from nour0205/fix/flowchart-inherit-dir
feat(flowchart): add inheritDir option for subgraph direction
2025-05-07 20:06:49 +00:00
Ashish Jain
c6d8590d8f Merge pull request #6541 from nour0205/docs/fix-annotation-style-clarification
docs(classDiagram): Clarify annotation syntax and recommend inline st…
2025-05-07 20:01:46 +00:00
Ashish Jain
10505a0392 Merge pull request #6575 from mermaid-js/omkar/fix-er-diagram-row-height-adjustment
Fix: Adjust ER diagram row height calculation and layout rendering
2025-05-07 19:59:05 +00:00
Knut Sveidqvist
e0a075ecca Adding treemap 2025-05-07 18:16:00 +02:00
omkarht
2a10143406 Fix: Adjust ER diagram row height calculation and layout rendering 2025-05-07 20:47:15 +05:30
Knut Sveidqvist
40eb0cc240 Passing tests 2025-05-07 16:15:14 +02:00
Sidharth Vinod
d702a7164e Merge pull request #6574 from mermaid-js/sidv/updateImages
fix: Update images
2025-05-07 15:13:12 +05:30
Sidharth Vinod
8a0bc64282 Merge pull request #6573 from mermaid-js/sidv/fixAvatarFetch
chore: Batch avatar download to avoid GitHub rate limiting.
2025-05-07 15:12:08 +05:30
Sidharth Vinod
ac0283ff97 fix: Update images 2025-05-07 15:10:22 +05:30
Sidharth Vinod
84faddc9e5 chore: Batch avatar download to avoid GitHub rate limiting. 2025-05-07 12:24:29 +05:30
Sidharth Vinod
5e3f21f572 Merge pull request #6570 from mermaid-js/sidv/ogTags
feat: Add og tags
2025-05-06 20:51:26 +05:30
Sidharth Vinod
05c74ed9ce feat: Add og tags 2025-05-06 20:44:15 +05:30
Sidharth Vinod
b106346119 Merge pull request #6568 from mermaid-js/announcement-bar-update
chore: Update announcement bar
2025-05-06 10:43:04 +05:30
rajat-ht
c09232c44d chore: update utm_campaign 2025-05-06 03:52:21 +05:30
rajat-ht
714496af6d chore: minor change 2025-05-06 03:46:01 +05:30
rajat-ht
5d61a30237 chore: update as per suggestion 2025-05-06 03:30:49 +05:30
rajat-ht
02ff3c1216 chore: Update announcement bar 2025-05-05 21:17:09 +05:30
autofix-ci[bot]
1f897a851b [autofix.ci] apply automated fixes 2025-05-05 12:30:50 +00:00
Arpit Jain
8af636c58d Fix Incomplete string escaping or encoding
errors
2025-05-05 12:15:41 +00:00
Sidharth Vinod
954f6cc8fc Merge branch 'develop' into sidv/examples
* develop: (189 commits)
  chore(deps): update dependency vite to v6.1.6 [security]
  corrected font size text
  docs(theme): fix table formatting by removing extra line between fontFamily and fontSize
  chore(deps): update dependency eslint-plugin-unicorn to v59
  chore(deps): update dependency vite to v6.1.5 [security]
  docs(theme): document fontFamily customization in themeVariables
  chore(deps): update eslint
  chore(deps): update peter-evans/create-pull-request digest to 3b1f4bf
  chore(deps): update dependency vite to v6.1.5 [security]
  Added the changeset
  Deleted unused code
  Deleted unused method
  chore: update E2E timings
  added changeset and unit test
  fix(sequenceDiagram): allow empty message after colon (Fixes #6518)
  chore(deps): update wei/curl digest to 012398a
  `layout-elk` package documentation misleading version
  [autofix.ci] apply automated fixes
  code review - wording and removals
  [autofix.ci] apply automated fixes
  ...
2025-05-02 02:32:50 +05:30
Sidharth Vinod
a566353030 Merge pull request #6549 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.6 [security]
2025-05-02 02:24:52 +05:30
renovate[bot]
d396c6b760 chore(deps): update dependency vite to v6.1.6 [security] 2025-05-01 20:52:36 +00:00
Sidharth Vinod
8d9f027f40 Merge pull request #6544 from nourhenta/fix-fontFamily-docs-v2
docs(theme): document fontFamily customization in themeVariables
2025-05-02 02:21:03 +05:30
Sidharth Vinod
560700eaf8 Merge pull request #6540 from mermaid-js/renovate/major-eslint
chore(deps): update dependency eslint-plugin-unicorn to v59
2025-05-01 20:18:23 +00:00
nourhenta
819843cf2a corrected font size text 2025-05-01 20:53:37 +01:00
Sidharth Vinod
5e2870f6f2 Merge pull request #6545 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.5 [security]
2025-04-29 13:22:53 +00:00
nourhenta
c364ff463a docs(theme): fix table formatting by removing extra line between fontFamily and fontSize 2025-04-29 13:31:42 +01:00
renovate[bot]
8738288bc0 chore(deps): update dependency eslint-plugin-unicorn to v59 2025-04-29 06:51:00 +00:00
Sidharth Vinod
74ef4ce9c6 Merge pull request #6479 from Shahir-47/feature/3250/add_vertline_to_gantt_plot
feat: Add vertical line to gantt plot at specified time
2025-04-29 06:25:57 +00:00
renovate[bot]
2b41bf083c chore(deps): update dependency vite to v6.1.5 [security] 2025-04-29 06:24:35 +00:00
Sidharth Vinod
249f22763b Merge pull request #6522 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.5 [security]
2025-04-29 11:53:03 +05:30
Sidharth Vinod
444d35b9b4 Merge pull request #6513 from mermaid-js/renovate/peter-evans-create-pull-request-digest
chore(deps): update peter-evans/create-pull-request digest to 3b1f4bf
2025-04-29 11:52:38 +05:30
Sidharth Vinod
83543bc790 Merge pull request #6539 from mermaid-js/renovate/eslint
chore(deps): update eslint (minor)
2025-04-29 11:52:22 +05:30
nourhenta
379559c992 docs(theme): document fontFamily customization in themeVariables 2025-04-28 23:06:02 +01:00
Megan Triplett
c61b879711 Merge branch 'develop' into feature/3250/add_vertline_to_gantt_plot 2025-04-28 16:22:07 -04:00
renovate[bot]
67806022b9 chore(deps): update eslint 2025-04-28 19:56:38 +00:00
nour kouider
f8c54317c5 docs(classDiagram): Clarify annotation syntax and recommend inline style (#6538) 2025-04-28 10:27:06 +01:00
renovate[bot]
65f778d183 chore(deps): update peter-evans/create-pull-request digest to 3b1f4bf 2025-04-28 06:44:55 +00:00
renovate[bot]
ed67c36440 chore(deps): update dependency vite to v6.1.5 [security] 2025-04-28 06:44:24 +00:00
Knut Sveidqvist
908043183e Merge pull request #6523 from NourBenz/bug/6518_allow-empty-colon-messaage
fix(sequenceDiagram): allow empty message after colon (Fixes #6518)
2025-04-28 06:30:32 +00:00
nghtlinh
97b79c3578 Added the changeset 2025-04-27 14:09:39 -04:00
nghtlinh
8d4c5d5278 Deleted unused code 2025-04-27 13:51:38 -04:00
nghtlinh
9988a61ec5 Merge remote-tracking branch 'origin/feature/3250/add_vertline_to_gantt_plot' into feature/3250/add_vertline_to_gantt_plot 2025-04-25 15:58:38 -04:00
nghtlinh
d4e737e451 Deleted unused method 2025-04-25 15:43:00 -04:00
NourBenz
b821454927 Merge branch 'develop' into bug/6518_allow-empty-colon-messaage 2025-04-25 19:01:21 +01:00
Sidharth Vinod
cee43a45f6 Merge pull request #6355 from mermaid-js/update-homepage
DOCS: Update homepage
2025-04-24 21:12:40 +05:30
Monica Nguyen
475532a839 Merge branch 'develop' into feature/3250/add_vertline_to_gantt_plot 2025-04-24 11:39:10 -04:00
Sidharth Vinod
c8daf9aa43 docs: Update tiny doc 2025-04-24 12:53:04 +05:30
Sidharth Vinod
cf8fc2a541 Merge pull request #6514 from mermaid-js/renovate/wei-curl-digest
chore(deps): update wei/curl digest to 012398a
2025-04-24 12:38:30 +05:30
Sidharth Vinod
08b6524a35 Merge pull request #6511 from SimonMarquis/patch-1
`layout-elk` package documentation misleading version
2025-04-24 11:21:55 +05:30
Sidharth Vinod
221aa3ed19 Merge pull request #6515 from mermaid-js/update-timings
Update E2E Timings
2025-04-24 11:20:27 +05:30
github-actions[bot]
640a65f9a7 chore: update E2E timings 2025-04-24 04:07:51 +00:00
NourBz
c17277e743 added changeset and unit test 2025-04-22 21:45:24 +01:00
NourBz
7b3fd044e8 fix(sequenceDiagram): allow empty message after colon (Fixes #6518) 2025-04-22 21:18:03 +01:00
Megan Triplett
566b3db15f Merge branch 'mermaid-js:develop' into feature/3250/add_vertline_to_gantt_plot 2025-04-22 15:16:18 -04:00
renovate[bot]
2483e6e434 chore(deps): update wei/curl digest to 012398a 2025-04-21 02:47:37 +00:00
Simon Marquis
e7b39f3fa3 layout-elk package documentation misleading version
It shows `layout-elk@11` in CDN code snippet while this package is currently on v0.1.7.
2025-04-20 12:44:44 +01:00
Sidharth Vinod
19884294bc chore: Move packet diagram out of beta 2025-04-20 14:09:27 +05:30
Sidharth Vinod
e6b63fd70a chore: Bump beta version to publish 2025-04-20 13:48:11 +05:30
Sidharth Vinod
1c1d7d0300 Merge pull request #6282 from mermaid-js/saurabh/refactor-fontawesome-icon-usage
Refactor fontawesome icon usage.
2025-04-20 01:04:40 -07:00
Sidharth Vinod
e8ee4bdb48 Merge pull request #6506 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.5 [security]
2025-04-20 05:57:33 +00:00
Sidharth Vinod
2afa96c2a8 Merge pull request #6495 from generrosity/patch-1
DOC: more complete gantt example
2025-04-20 05:56:50 +00:00
autofix-ci[bot]
7c42d08ef2 [autofix.ci] apply automated fixes 2025-04-20 05:42:45 +00:00
generrosity
d0520e6a50 code review - wording and removals
- wording choice to match writing
- removing incorrect assumptions about String quotation and insensitivity.

Co-authored-by: Sidharth Vinod <github@sidharth.dev>
2025-04-20 17:38:10 +12:00
autofix-ci[bot]
a703a195d4 [autofix.ci] apply automated fixes 2025-04-20 05:25:49 +00:00
generrosity
05b5607265 removing directives note
misundeerstood

Co-authored-by: Sidharth Vinod <github@sidharth.dev>
2025-04-20 17:21:19 +12:00
renovate[bot]
2b28966f8d chore(deps): update dependency vite to v6.1.5 [security] 2025-04-19 13:50:59 +00:00
Sidharth Vinod
4077088f18 test: Tweak flowchart tests 2025-04-19 18:19:36 +05:30
Sidharth Vinod
867484a2cc Revert "temp: Remove tests to check if cypress passes"
This reverts commit b0b76ef7a2.
2025-04-19 18:12:03 +05:30
Sidharth Vinod
5ea7088e04 test: fix flowchart width in test 2025-04-19 18:11:44 +05:30
autofix-ci[bot]
646230d603 [autofix.ci] apply automated fixes 2025-04-19 10:01:32 +00:00
generrosity
5a7e734da4 sp check 2025-04-19 21:57:08 +12:00
generrosity
2924b94fbc Merge branch 'develop' into patch-1 2025-04-19 20:53:34 +12:00
generrosity
f8c6ae5d17 stripping comments from gantt example
as requested, I've pulled comments onto the main syntax pages, so stripping many of the comments from here
2025-04-19 20:07:12 +12:00
generrosity
8d7330aeb3 Adding to mermaid syntax
Following on from recommendation from code senior👌;

adding details to mermaid syntax in a more useful location;
- comments (tho not totally truethful)
- indenting
- case insensitive
- string handling
- expectations with invalid keywords or parameters
2025-04-19 20:04:30 +12:00
generrosity
6a6c9f6254 Add Frontmatteer to syntax more explicitly 2025-04-19 19:38:14 +12:00
Sidharth Vinod
b0b76ef7a2 temp: Remove tests to check if cypress passes 2025-04-19 11:39:43 +05:30
Sidharth Vinod
53e89d97a0 Merge branch 'develop' into saurabh/refactor-fontawesome-icon-usage 2025-04-18 12:39:47 -07:00
Sidharth Vinod
59b400652b Merge pull request #6302 from guzzit/patch-1
Added class styling example to block.md
2025-04-18 19:08:58 +00:00
Sidharth Vinod
e8124d8828 Merge pull request #6340 from Baraka24/docs/6339_add-tiki-to-integrations-community-list
docs(integrations): add tiki to community list cms/ecm
2025-04-18 19:07:42 +00:00
Sidharth Vinod
26e3bea2fe Merge pull request #6349 from IceFreez3r/docs/parameters-header-level
Docs/Fix parameter heading level
2025-04-18 19:06:50 +00:00
Sidharth Vinod
1fda77db13 Merge pull request #6383 from suelambot/docs/6382_error-class-diag-action-full-example
6382 - fix error on classDiagram.md
2025-04-18 19:04:57 +00:00
Sidharth Vinod
5b2227b3be Merge pull request #6418 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v6.1.5 [security]
2025-04-18 19:00:16 +00:00
Sidharth Vinod
68670535bf docs: Update tiny docs 2025-04-18 17:16:51 +05:30
renovate[bot]
7a6f13707f chore(deps): update dependency vite to v6.1.5 [security] 2025-04-18 11:20:41 +00:00
Sidharth Vinod
9d838d4e7a fix: e2e-applitools.yml 2025-04-18 16:48:58 +05:30
Sidharth Vinod
a92ae7a16c chore: Update katex message 2025-04-18 15:53:37 +05:30
Sidharth Vinod
8800de9309 Merge branch 'sidv/tinyMermaid' of https://github.com/mermaid-js/mermaid into sidv/tinyMermaid
* 'sidv/tinyMermaid' of https://github.com/mermaid-js/mermaid:
  [autofix.ci] apply automated fixes
2025-04-18 15:51:58 +05:30
Sidharth Vinod
d2c53552ff chore: Disable sourcemap for tiny 2025-04-18 15:51:42 +05:30
autofix-ci[bot]
91a7564db6 [autofix.ci] apply automated fixes 2025-04-18 10:12:40 +00:00
Sidharth Vinod
a037cdcf13 chore: patch bump tiny 2025-04-18 15:34:29 +05:30
Sidharth Vinod
3753967c8f fix: Update tiny file name 2025-04-18 15:33:31 +05:30
Sidharth Vinod
549dc86b21 chore: Revert unrelated changes 2025-04-18 15:26:23 +05:30
Sidharth Vinod
e97f25f13e chore: Match tiny version 2025-04-18 15:18:05 +05:30
Sidharth Vinod
c3c609a965 chore: Remove changelog for tiny 2025-04-18 15:17:50 +05:30
Sidharth Vinod
c81a7d13e0 chore: Revert unrelated changes 2025-04-18 15:13:14 +05:30
Sidharth Vinod
e561acac23 chore: Remove unnecessary workflows 2025-04-18 15:09:53 +05:30
Sidharth Vinod
86a0a7fe3a chore: Add sourcemaps back 2025-04-18 15:09:04 +05:30
Sidharth Vinod
5a8f32b8cb Merge branch 'sidv/tinyMermaid' of https://github.com/mermaid-js/mermaid into sidv/tinyMermaid
* 'sidv/tinyMermaid' of https://github.com/mermaid-js/mermaid:
  [autofix.ci] apply automated fixes
2025-04-18 15:06:49 +05:30
autofix-ci[bot]
c6e640ab75 [autofix.ci] apply automated fixes 2025-04-18 09:36:34 +00:00
Sidharth Vinod
f6862c5af5 chore: Tiny version 2025-04-18 15:05:17 +05:30
Sidharth Vinod
bd8b93327e chore: Tiny version 2025-04-18 15:05:02 +05:30
Sidharth Vinod
4a63901af9 chore: Copy changelog to tiny 2025-04-18 15:02:16 +05:30
Sidharth Vinod
8c52edf3ef chore: Move architecture into largeFeature 2025-04-18 14:56:13 +05:30
Sidharth Vinod
da610bff1d chore: Add @mermaid-js/tiny package 2025-04-18 14:55:53 +05:30
Sidharth Vinod
db389e589d Merge branch 'develop' into sidv/tinyMermaid
* develop: (1682 commits)
  docs: Fix casing of Frontmatter config
  spelling: youtube
  spelling: without
  spelling: withdrawal
  spelling: very
  spelling: typescript
  spelling: tooltip
  spelling: to
  spelling: threshold
  spelling: themeable
  spelling: the
  spelling: than
  spelling: text
  spelling: task
  spelling: syntax
  spelling: svg
  spelling: subgraphs
  spelling: style
  spelling: string
  spelling: strict
  ...
2025-04-18 14:10:49 +05:30
Sidharth Vinod
24aec8c280 Merge pull request #6343 from jeswr/fix/timeline-event-colons
fix: allow colons in events
2025-04-18 08:30:02 +00:00
Sidharth Vinod
8c4fc3c6ff Merge pull request #5993 from jakebeamish/patch-1
Fix code block typo in syntax-reference.md
2025-04-18 01:24:15 -07:00
Sidharth Vinod
d72ee5fc95 Merge pull request #6502 from jsoref/spelling
chore: Fix spelling
2025-04-18 01:21:21 -07:00
Sidharth Vinod
b3ff80f211 Merge pull request #6499 from jsoref/docs/6498_remove-deprecated-init-config
chore: Remove deprecated init config
2025-04-18 08:06:08 +00:00
Sidharth Vinod
8a34154efa docs: Fix casing of Frontmatter config 2025-04-18 13:28:41 +05:30
autofix-ci[bot]
79b47be35f [autofix.ci] apply automated fixes 2025-04-18 03:52:33 +00:00
generrosity
054f5444d6 spellchecked
inconsistently misspelling inconsistently misspelling
2025-04-18 15:48:08 +12:00
generrosity
beb80db25a shift directives to frontmatter
* shifting directives to frontmatter as recomended - it is literally about to me removed, 
* tweaking context comment about directives
* tweaking code in general formatting, spelling, wording
2025-04-18 15:37:50 +12:00
generrosity
fbdbd9d0dd Merge branch 'develop' into patch-1 2025-04-18 15:35:17 +12:00
Josh Soref
8ce1f70066 spelling: youtube
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
334294c6af spelling: without
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
e0f3f2bd5a spelling: withdrawal
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
6dad2ab327 spelling: very
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
4d2e424c30 spelling: typescript
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
ff217957fc spelling: tooltip
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
866b29c050 spelling: to
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
a463d11e57 spelling: threshold
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
5267f7c6ea spelling: themeable
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
2bdecc2842 spelling: the
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
d8efe9a55d spelling: than
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
ae564f30af spelling: text
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
2a6da19956 spelling: task
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
de41669320 spelling: syntax
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
02b997f4e4 spelling: svg
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
90c0908ed5 spelling: subgraphs
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
a7d76b2695 spelling: style
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
e46c7ae996 spelling: string
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
af7a5fe77d spelling: strict
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
f9fbadbbe2 spelling: state
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
dec82de586 spelling: some
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
598c72853f spelling: sibling
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
b1e1a0c0d7 spelling: should
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
a9f3b432ff spelling: set
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
cd2ab38927 spelling: semicolon
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
04448e3b6a spelling: section
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
2a12a64c06 spelling: router
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
586b528a16 spelling: righty
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
36e6e6e1be spelling: rendering
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
1de7d31d90 spelling: quotation
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
34d91d0e88 spelling: previously
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:55 -04:00
Josh Soref
101dc6d52c spelling: precedence
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
1fbe17e04c spelling: possible
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
8fed1c86b0 spelling: on
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
b808801347 spelling: nonexistent
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
58ec4ca39f spelling: node
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
7e3d547094 spelling: neither-nor
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
79f010143a spelling: mobile
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
aa9df775cd spelling: misspelling
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
2601ec89c8 spelling: markdown
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
566415c189 spelling: make
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
cbabc7b709 spelling: lefty
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
873962c739 spelling: label
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
2aeb435f19 spelling: kick-start
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
e0818c9e47 spelling: key
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
a3753d8f4d spelling: javascript
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
308e2cc107 spelling: is
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
a578cb8def spelling: is not
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
a823bf043b spelling: introduced
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
3980c99c22 spelling: into
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
c81f63b462 spelling: id
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
16167a64e5 spelling: html
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
cba4d733f0 spelling: hierarchy
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
6a0fb67ab7 spelling: hierarchical
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
4bfd0f753d spelling: have
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
bf83262d7c spelling: handle huge
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
ccdd0f0146 spelling: handdrawn
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
82646432a1 spelling: grammar
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
c82579097c spelling: github
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
92132ad4f1 spelling: gitgraph
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
8564ebbdbd spelling: fundamentals
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
1ca6ff93ff spelling: from
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
20098b287b spelling: for
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
0474a8422b spelling: for example
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
075f0f580f spelling: excluding
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
78ded6452f spelling: even though
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
08085b8821 spelling: distinguish
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
5f35d70ce2 spelling: detected
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
08951dbbf0 spelling: delegate
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
7caf377963 spelling: definition
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
0103da0179 spelling: cspell:ignore
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
a6c9ab04dc spelling: corresponding
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
b9c472e091 spelling: compound
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
4ed4756220 spelling: columns
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
4b12ebee51 spelling: code paths
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
d6e1541bc8 spelling: cluster
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
0507fe114e spelling: cannot
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
2bb77406fb spelling: bypass
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:54 -04:00
Josh Soref
2215bf6aaa spelling: bullet
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
206cc51578 spelling: bronze
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
c4c55277cb spelling: boundaries
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
0c2d222aa6 spelling: beginning
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
fc3d4859db spelling: been
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
c7714fd666 spelling: backticked
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
e2bf95c922 spelling: backslash
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
a79a50b77f spelling: axis
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
9133fcb9a8 spelling: axis name
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
00e9ed2024 spelling: assignments
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
5919d39812 spelling: and
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
f5fa0ae876 spelling: an
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
de9eb67040 spelling: accessibilities
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
cb7518a960 spelling: a
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
34bf5c8be1 Shorten alt text 2025-04-17 17:38:53 -04:00
Josh Soref
7d1319f97c Clarify that a is a tag 2025-04-17 17:38:53 -04:00
Josh Soref
9c46e960e7 link: theming your diagram
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
cd956e1b60 link: mermaid needs more Collaborators
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
78cf1706a9 link: list of currently used variable names
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
607e9ab989 link: implementation in the live editor
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
Josh Soref
0cf0b684cf link: add custom icons
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2025-04-17 17:38:53 -04:00
autofix-ci[bot]
cb0cb5dfc7 [autofix.ci] apply automated fixes 2025-04-17 17:50:20 +00:00
Josh Soref
330c48fa3f chore: Use yaml instead of note for standalone config: example 2025-04-17 13:45:27 -04:00
Josh Soref
2ff6de11dc chore: Change %%{init...}%% to config: 2025-04-17 13:42:28 -04:00
Josh Soref
385fab8c67 chore: Remove trailing whitespace 2025-04-17 13:42:28 -04:00
Udval E.
e49911e748 Merge branch 'develop' into feature/3250/add_vertline_to_gantt_plot 2025-04-17 12:21:17 -04:00
autofix-ci[bot]
8a84ede164 [autofix.ci] apply automated fixes 2025-04-17 16:17:01 +00:00
Sidharth Vinod
d79b7b2d97 Merge branch 'sidv/examples' of https://github.com/mermaid-js/mermaid into sidv/examples
* 'sidv/examples' of https://github.com/mermaid-js/mermaid: (110 commits)
  [autofix.ci] apply automated fixes
  chore: Change `mermaid` blocks to `mermaid-example` in docs
  chore: Remove duplicate `mermaid` blocks
  chore: update E2E timings
  [autofix.ci] apply automated fixes
  chore: Switch from `%%{init` to `config:`
  chore: Add details to e2e-timings
  chore: Ignore timeout domains
  [autofix.ci] apply automated fixes
  [autofix.ci] apply automated fixes
  Create neat-moose-compare.md
  chore: Add changeset
  updated tests
  modified description of showDataLabel in config schema and added it to docs
  fix(deps): update all major dependencies
  chore(deps): update peter-evans/create-pull-request digest to a7b20e1
  fix(deps): update dependency dompurify to ^3.2.5
  [autofix.ci] apply automated fixes
  Update integrations-community.md
  [autofix.ci] apply automated fixes
  ...
2025-04-17 21:42:14 +05:30
Sidharth Vinod
844f879f63 fix: Examples unit test 2025-04-17 21:42:05 +05:30
Sidharth Vinod
cf789d2c91 Merge branch 'develop' into sidv/examples 2025-04-17 09:06:50 -07:00
Sidharth Vinod
4936ef5c30 chore: Split changeset
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-04-17 21:32:10 +05:30
Sidharth Vinod
f006718e56 chore: Change getDiagramData to getRegisteredDiagramsMetadata
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-04-17 21:30:48 +05:30
Sidharth Vinod
d720776918 Merge branch 'sidv/examples' of https://github.com/mermaid-js/mermaid into sidv/examples
* 'sidv/examples' of https://github.com/mermaid-js/mermaid:
  Update packages/examples/tsconfig.json
2025-04-17 21:28:07 +05:30
Sidharth Vinod
f43398dd44 Update packages/examples/tsconfig.json
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-04-17 08:57:53 -07:00
Sidharth Vinod
43ad451940 fix: Remove unnecessary export from package.json
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-04-17 21:26:46 +05:30
Sidharth Vinod
94c099caa1 docs: Update kanban example
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-04-17 21:26:10 +05:30
Sidharth Vinod
a3fed10d55 Merge pull request #6497 from jsoref/docs/6496_fix-duplicate-and-missing-examples
chore: Fix duplicate and missing examples
2025-04-17 14:11:12 +00:00
autofix-ci[bot]
2a859f2739 [autofix.ci] apply automated fixes 2025-04-17 11:08:43 +00:00
generrosity
dbbe014c5b Merge branch 'develop' into patch-1 2025-04-17 23:02:53 +12:00
Josh Soref
c7fa906115 chore: Change mermaid blocks to mermaid-example in docs 2025-04-17 06:50:20 -04:00
Josh Soref
3c69bd34c7 chore: Remove duplicate mermaid blocks 2025-04-17 06:46:24 -04:00
autofix-ci[bot]
ceef0558be [autofix.ci] apply automated fixes 2025-04-17 10:44:26 +00:00
generrosity
63b90e8b9b tweaks
adding some of the correct terms and references, depreciation
2025-04-17 22:23:21 +12:00
Sidharth Vinod
f5d27bf7ef Merge pull request #6491 from jsoref/docs/6490_convert-from-init-to-config
chore: Switch from `%%{init` to `config:`
2025-04-17 04:33:19 +00:00
Sidharth Vinod
5a03f07853 Merge pull request #6486 from mermaid-js/update-timings
Update E2E Timings
2025-04-16 21:35:14 -07:00
github-actions[bot]
8474cf43fe chore: update E2E timings 2025-04-17 04:05:18 +00:00
autofix-ci[bot]
f56895832f [autofix.ci] apply automated fixes 2025-04-16 20:46:18 +00:00
Josh Soref
8975a1907a chore: Switch from %%{init to config:
Use format which works reliably...
2025-04-16 16:40:13 -04:00
udvale
62b4228df4 changed some color aspects for vertline based on theme 2025-04-16 15:44:21 -04:00
udvale
c552dc7551 Add documentation for vert feature in Gantt chart
Co-authored-by: Monica Nguyen <nghtlinh25@gmail.com>
Co-authored-by: Megan Triplett <megantriplett10@gmail.com>
2025-04-16 14:52:24 -04:00
generrosity
e425a45755 extra sample gantt chart with extras 2025-04-16 21:15:14 +12:00
megantriplett
d177211286 added a snapshot test 2025-04-15 15:55:57 -04:00
Monica Nguyen
a07d365c1c Merge branch 'develop' into feature/3250/add_vertline_to_gantt_plot 2025-04-15 15:46:45 -04:00
Jesse Wright
1f512e9671 Merge branch 'develop' into fix/timeline-event-colons 2025-04-15 12:03:58 +01:00
Sidharth Vinod
12b6371abf chore: Add details to e2e-timings 2025-04-15 12:37:34 +05:30
Sidharth Vinod
88ae4ef704 chore: Remove incorrect language tag 2025-04-15 12:21:46 +05:30
Sidharth Vinod
df9df9dc32 docs: Add changeset 2025-04-15 12:16:49 +05:30
Sidharth Vinod
ea321168bd chore: Update bits syntax to use +<count> 2025-04-15 12:14:06 +05:30
Sidharth Vinod
d7730aba46 Merge branch 'develop' into pr/BryanCrotazGivEnergy/5980
* develop: (492 commits)
  chore: Ignore timeout domains
  [autofix.ci] apply automated fixes
  [autofix.ci] apply automated fixes
  Create neat-moose-compare.md
  chore: Add changeset
  updated tests
  modified description of showDataLabel in config schema and added it to docs
  fix(deps): update all major dependencies
  chore(deps): update peter-evans/create-pull-request digest to a7b20e1
  fix(deps): update dependency dompurify to ^3.2.5
  [autofix.ci] apply automated fixes
  Update integrations-community.md
  [autofix.ci] apply automated fixes
  Add Mermaid plus for Confluence into integrations-community.md
  refactor xy-chart tests
  added new tests
  added new tests
  chore(deps): update eslint
  chore: Update change detection logic
  chore: Use git to read old timings
  ...
2025-04-15 11:45:33 +05:30
Sidharth Vinod
5310d60e63 Merge pull request #6296 from mermaid-js/sidv/stateDB-ts
chore: Convert StateDB to TS
2025-04-15 04:10:13 +00:00
Sidharth Vinod
3ae87ca06a chore: Ignore timeout domains 2025-04-15 09:42:52 +05:30
Sidharth Vinod
24f23efdad Merge branch 'develop' into saurabh/refactor-fontawesome-icon-usage 2025-04-14 20:15:48 -07:00
Sidharth Vinod
e2520dde20 Merge branch 'develop' into sidv/stateDB-ts 2025-04-14 20:14:58 -07:00
Sidharth Vinod
3e8204aa21 Merge pull request #6365 from mermaid-js/renovate/major-all-major
fix(deps): update all major dependencies (major)
2025-04-15 03:13:33 +00:00
Sidharth Vinod
0b57984d27 Merge pull request #6475 from Shahir-47/feature/5806_xy-chart-data-labels
feat: Dynamically Render Data Labels Within Bar Charts
2025-04-15 03:13:03 +00:00
Sidharth Vinod
bcaa40f1d5 Merge pull request #6225 from Shahir-47/feature/3508_color-user-journey-title
feat: Add support for styling Journey Diagram title (color, font-family, and font-size)
2025-04-15 03:12:24 +00:00
autofix-ci[bot]
0107494b59 [autofix.ci] apply automated fixes 2025-04-15 02:32:13 +00:00
autofix-ci[bot]
11c3ac58fd [autofix.ci] apply automated fixes 2025-04-15 02:25:23 +00:00
Sidharth Vinod
af2eb13932 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-04-14 19:23:47 -07:00
Sidharth Vinod
41e84b726a Create neat-moose-compare.md 2025-04-14 19:23:19 -07:00
Sidharth Vinod
a1ba65c0c0 chore: Add changeset 2025-04-14 19:20:47 -07:00
Shahir Ahmed
5fe6e5dccc Merge branch 'develop' into feature/5806_xy-chart-data-labels
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-14 14:44:53 -04:00
pranavm2109
946452c7b4 updated tests
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-04-14 14:38:23 -04:00
pranavm2109
4bb6351489 modified description of showDataLabel in config schema and added it to docs
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-04-14 13:53:18 -04:00
renovate[bot]
8c63a2e411 fix(deps): update all major dependencies 2025-04-14 07:25:55 +00:00
Sidharth Vinod
4467fd4363 Merge pull request #6482 from mermaid-js/renovate/peter-evans-create-pull-request-digest
chore(deps): update peter-evans/create-pull-request digest to a7b20e1
2025-04-14 07:09:53 +00:00
renovate[bot]
7e567a8759 chore(deps): update peter-evans/create-pull-request digest to a7b20e1 2025-04-14 06:17:30 +00:00
Ashish Jain
edf062720d Merge pull request #6459 from mermaid-js/renovate/patch-dompurify
fix(deps): update dependency dompurify to ^3.2.5
2025-04-14 06:03:40 +00:00
renovate[bot]
3348eea6af fix(deps): update dependency dompurify to ^3.2.5 2025-04-14 04:46:04 +00:00
Sidharth Vinod
ae7ffab9ac Merge pull request #6483 from universeroc/develop
Add Mermaid plus for Confluence into integrations-community.md
2025-04-14 04:32:13 +00:00
autofix-ci[bot]
ecdbc676d2 [autofix.ci] apply automated fixes 2025-04-14 04:01:42 +00:00
universeroc
6a01b04e3c Update integrations-community.md 2025-04-14 11:55:45 +08:00
autofix-ci[bot]
aafe8de3d3 [autofix.ci] apply automated fixes 2025-04-14 03:52:31 +00:00
universeroc
24287637b5 Add Mermaid plus for Confluence into integrations-community.md 2025-04-14 11:43:32 +08:00
Shahir Ahmed
f69cc17795 refactor xy-chart tests
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-11 16:24:10 -04:00
nghtlinh
f5c99a2a4f Deleted "special" tag residue 2025-04-11 16:04:14 -04:00
nghtlinh
244703a904 Merge branch 'monica_branch' of https://github.com/Shahir-47/mermaid into monica_branch 2025-04-11 15:18:09 -04:00
Monica Nguyen
59a9e1b300 Merge branch 'mermaid-js:develop' into monica_branch 2025-04-11 15:15:40 -04:00
nghtlinh
167a625413 Merge branch 'monica_branch' of https://github.com/Shahir-47/mermaid into monica_branch 2025-04-11 15:13:00 -04:00
nghtlinh
296cb64fa5 deleted repeated code 2025-04-11 15:11:14 -04:00
Shahir Ahmed
934f4da507 Merge remote-tracking branch 'origin/develop' into feature/3508_color-user-journey-title
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-11 00:16:46 -04:00
Shahir Ahmed
6957f35782 Merge branch 'develop' into feature/5806_xy-chart-data-labels
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-10 21:42:37 -04:00
Shahir Ahmed
b00be59ea8 added new tests
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-10 21:22:36 -04:00
Shahir Ahmed
dff00f2c4f added new tests
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-10 21:04:55 -04:00
udvale
2009177375 the title is centered at vert line 2025-04-10 16:35:41 -04:00
Sidharth Vinod
eb9987435a Merge pull request #6364 from mermaid-js/renovate/eslint
chore(deps): update eslint (minor)
2025-04-10 07:18:54 +00:00
Sidharth Vinod
a300d0db94 Merge pull request #6391 from regisbsb/patch-1
Remove duplicates in integrations-community.md
2025-04-10 07:16:37 +00:00
Sidharth Vinod
7e7f3c56c2 Merge pull request #6456 from nour0205/fix/edge-id-en-dash-docs-6455
fix(docs): fix edge ID example
2025-04-10 07:10:08 +00:00
nghtlinh
81fa2a675f Rendered vert task at last + Trying to reposition vert label 2025-04-09 18:15:26 -04:00
nghtlinh
2203792164 Added permananet color for the vertical line 2025-04-09 16:13:34 -04:00
nghtlinh
5bbc9b4f5b Merge branch 'Issue3250/addDateToGantt' into monica_branch 2025-04-09 15:44:04 -04:00
renovate[bot]
ea987861f3 chore(deps): update eslint 2025-04-09 13:45:21 +00:00
Sidharth Vinod
8005262d76 Merge branch 'master' into update-homepage
* master: (242 commits)
  update logic
  Version Packages
  Add missing changeset for requirement diagram fix
  Update mermaid version palceholder
  test(e2e): fix Cypress config for Node.JS v20.19.0
  fix: restore curve type configuration functionality for flowcharts (#6193)
  update promo bar content
  rework contains geometry to avoid clipping
  try arrowhead
  #6380: move requirements containment arrow to start
  ⚗️ Add radar renderer tests
  🩹 Fix: text-color ➙ color
  [autofix.ci] apply automated fixes
  🆙 Run pnpm changeset
  🖼️ Add Radar Demo with custom opacity
  📚 Add documentation
  🖼️ Add Radar Demo
  ⚗️ Add Cypress test
  🎨 Add themes for radar
  📊 Add radar chart
  ...
2025-04-09 19:13:35 +05:30
nour kouider
463eb07979 fix(config.schema): add inheritDir to Flowchart config and regenerate types/docs 2025-04-09 11:34:06 +01:00
Sidharth Vinod
a3cf9de01b fix: Move Tooltip as vue component 2025-04-09 15:50:27 +05:30
Sidharth Vinod
9a90aca8e6 chore: Add mermaid logo 2025-04-09 15:35:58 +05:30
nour0205
8c9b38ed90 Merge branch 'develop' into fix/flowchart-inherit-dir 2025-04-09 11:04:49 +01:00
Sidharth Vinod
963b1e3ec5 chore: Fix intro link 2025-04-09 15:32:31 +05:30
Sidharth Vinod
208d29e3d6 chore: Update live editor link 2025-04-09 15:31:25 +05:30
Sidharth Vinod
5c865e7b71 chore: Remove duplicate cspell 2025-04-09 15:29:08 +05:30
Sidharth Vinod
7ce9dbcece docs: Add target to external link 2025-04-09 15:27:53 +05:30
nour kouider
36fe04bd46 feat(flowchart): add inheritDir option for subgraph direction 2025-04-09 10:56:30 +01:00
Sidharth Vinod
ff786b4ef8 docs: Update homepage links 2025-04-09 15:25:02 +05:30
Sidharth Vinod
b81b665137 feat: Add tooltip for MermaidChart links 2025-04-09 15:24:23 +05:30
Sidharth Vinod
178c7130c6 Merge pull request #6465 from aloisklink/build/fix-mermaid-zenuml
build: fix `mermaid-zenuml` IIFE build and add changesets
2025-04-09 01:42:37 -07:00
Sidharth Vinod
f87d0dd88a chore: Update change detection logic 2025-04-09 13:20:19 +05:30
Sidharth Vinod
2396f90269 Merge pull request #6467 from mermaid-js/sidv/checkTimings
Reduce timing update PRs
2025-04-08 23:54:15 -07:00
Sidharth Vinod
97e35fd30a chore: Use git to read old timings 2025-04-09 12:19:13 +05:30
Sidharth Vinod
7a5f999f42 chore: Add compare-timings script
Avoid creating unnecessary PRs when there is no significant timings change.
2025-04-09 12:08:57 +05:30
Sidharth Vinod
cd8d74bb96 Merge pull request #6274 from Shahir-47/bug/5955_adjust-diagram-position-with-legend-width
fix: Prevent Legend Labels from Overlapping Diagram Elements in Journey Diagrams
2025-04-08 17:17:06 +00:00
Sidharth Vinod
3e6f680df2 chore: Reorder fields in examples 2025-04-08 20:14:36 +05:30
Sidharth Vinod
56c6853e05 Merge pull request #6463 from AaronMoat/undefined
Fix incorrect `style="undefined;"` output in some Mermaid diagrams
2025-04-08 12:46:11 +00:00
Sidharth Vinod
2e5d955e77 Update packages/examples/src/examples/kanban.ts
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-08 04:39:41 -07:00
Sidharth Vinod
7733faf6c4 Merge branch 'sidv/examples' of https://github.com/mermaid-js/mermaid into sidv/examples
* 'sidv/examples' of https://github.com/mermaid-js/mermaid:
  chore: update E2E timings
  chore: Update permission for timings action
  chore: Fix PR action in e2e-timings
  chore: Fix branch in e2e-timings
2025-04-08 17:08:13 +05:30
Sidharth Vinod
b053a88993 docs: Add steps to add examples for new diagrams 2025-04-08 17:07:56 +05:30
Sidharth Vinod
01e2af0cfd Merge pull request #6407 from thomascizeron/fix/6162_greedyRegexInCommonLangium
Fix: greedy regex in common langium
2025-04-08 11:33:43 +00:00
Sidharth Vinod
f55ff99f74 Merge branch 'develop' into fix/6162_greedyRegexInCommonLangium 2025-04-08 04:25:20 -07:00
Aaron Moat
d25770ee73 Format changeset message 2025-04-08 19:55:05 +10:00
Aaron Moat
2b05d7e1ed Fix incorrect style="undefined;" output in some Mermaid diagrams 2025-04-08 19:49:47 +10:00
Sidharth Vinod
7c77c46ede Merge branch 'develop' into sidv/examples 2025-04-08 00:14:49 -07:00
Sidharth Vinod
30735266a4 Merge pull request #6461 from mermaid-js/update-timings
Update E2E Timings
2025-04-08 00:14:25 -07:00
github-actions[bot]
926862c196 chore: update E2E timings 2025-04-08 06:53:44 +00:00
Sidharth Vinod
44e668e704 chore: Update permission for timings action 2025-04-08 11:58:46 +05:30
Sidharth Vinod
404216273a chore: Fix PR action in e2e-timings 2025-04-08 11:01:28 +05:30
Sidharth Vinod
5a6831ae7e chore: Fix branch in e2e-timings 2025-04-08 10:13:59 +05:30
Sidharth Vinod
da6937f474 temp: Revert all changes is cypress folder 2025-04-08 10:08:06 +05:30
Sidharth Vinod
cbb496da79 Merge branch 'develop' into sidv/examples
* develop:
  docs: improve elk section of ER docs
  Fix formatting of ELK example in ERD + clarify usage
2025-04-08 10:05:04 +05:30
Alois Klink
03119fea2c chore(zenuml): add pending ZenUML changesets
Add ZenUML changesets for:

- Bumping the minimum version of ZenUML to 3.23.28
- Limiting the `peerDepdencies` to v10 and v11

See: 9d06d8f31e
See: 0ad44c12fe
2025-04-07 17:58:40 +08:00
Alois Klink
5351211256 build(zenuml): add back IIFE ZenUML builds
These are present in [v0.2.0][1] so removing these would be a breaking
change. I suspect we accidentally removed them when we moved from
Vite to ESBuild.

[1]: https://www.npmjs.com/package/@mermaid-js/mermaid-zenuml/v/0.2.0
2025-04-07 17:58:40 +08:00
Alois Klink
92c0aa4331 build(esbuild): support multiple IIFE packages
Support multiple IIFE packages by namespacing all of them into a
`globalThis.__esbuild_esm_mermaid_nm` object.
2025-04-07 17:58:40 +08:00
Alois Klink
7bd5c03d87 Merge pull request #6426 from internetisaiah/patch-1
Fix formatting of ELK example in ERD + clarify usage
2025-04-07 08:35:03 +00:00
Alois Klink
de72e18a7f docs: improve elk section of ER docs 2025-04-07 16:07:43 +08:00
khalil
3f493acc6a fixed unit test 2025-04-06 21:02:22 +01:00
khalil
d2239549e6 fixed unit test 2025-04-06 20:49:43 +01:00
khalil
f8d8f74f34 fixed unit test 2025-04-06 20:41:29 +01:00
khalil
74a9336d42 fixed unit test 2025-04-06 00:07:48 +01:00
khalil
ca2b16119d fixed unit test 2025-04-05 21:49:02 +01:00
khalil
2d9034c983 fixed unit test 2025-04-05 21:30:03 +01:00
khalil
aa6cb86899 added changeset and unit test 2025-04-05 20:46:16 +01:00
khalil
99797632ab reset branch and readded commits 2025-04-05 20:37:11 +01:00
nour kouider
4fdb1d5906 docs: correct edge syntax from -> to --> 2025-04-05 13:39:30 +01:00
Sidharth Vinod
43e66a6089 chore: Unskip example test 2025-04-05 14:02:58 +05:30
Sidharth Vinod
5acbd7e762 docs: Add changeset 2025-04-05 13:30:08 +05:30
Sidharth Vinod
febae345fc chore: Fix file extension 2025-04-05 09:25:31 +05:30
Sidharth Vinod
28bdbbca1a chore: Fix examples exports 2025-04-05 09:17:52 +05:30
Sidharth Vinod
4b896fa22e Merge branch 'sidv/examples' of https://github.com/mermaid-js/mermaid into sidv/examples
* 'sidv/examples' of https://github.com/mermaid-js/mermaid:
  [autofix.ci] apply automated fixes
2025-04-05 09:11:26 +05:30
Sidharth Vinod
a25ee49edd test: Add visual testing for examples 2025-04-05 09:11:18 +05:30
Sidharth Vinod
695b5b2fb2 fix: Build script 2025-04-05 09:10:58 +05:30
autofix-ci[bot]
9b77af540b [autofix.ci] apply automated fixes 2025-04-05 03:33:20 +00:00
Sidharth Vinod
7829138fb2 chore: Update lockfile 2025-04-05 08:58:31 +05:30
Sidharth Vinod
7e7a4fc665 chore: Move examples to different package 2025-04-05 08:53:37 +05:30
Shahir Ahmed
a2bf5103ce test for vertical xy-axis
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-04 21:44:00 -04:00
Shahir Ahmed
8b7a4db2ef test for horzontal xy-axis
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-04 21:34:46 -04:00
nghtlinh
a43965ac2c Put label right down the vert line 2025-04-04 15:57:55 -04:00
nghtlinh
8eb2000b98 Adjusted label calculation for x and y values 2025-04-04 15:44:09 -04:00
Shahir Ahmed
73f8dee643 add config to test files
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-04-04 15:22:40 -04:00
pranavm2109
8bdd7ec719 updated tests to account for showDataLabel set to false as default
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-04-04 15:20:51 -04:00
megantriplett
7e1cec95ef fixed bug where background is removed @monicanguyen25 @udvale 2025-04-04 15:17:02 -04:00
megantriplett
ec2c76a703 deleted some old commented out code 2025-04-04 15:02:54 -04:00
nour kouider
7facc8f50d docs: fix edge ID example and regenerate flowchart output 2025-04-04 19:04:02 +01:00
autofix-ci[bot]
52cd9e8e55 [autofix.ci] apply automated fixes 2025-04-04 17:37:42 +00:00
nour kouider
9208e7faaf fix(docs): fix edge ID example 2025-04-04 18:22:56 +01:00
nghtlinh
d0ee6079b3 Positioned the label in the center of the vert line + Brough back the background 2025-04-03 20:43:32 -04:00
Sidharth Vinod
34e6112fea Merge branch 'sidv/examples' of https://github.com/mermaid-js/mermaid into sidv/examples
* 'sidv/examples' of https://github.com/mermaid-js/mermaid:
  [autofix.ci] apply automated fixes
2025-04-03 17:10:45 +05:30
Sidharth Vinod
0c759d0075 chore: Add isDefault to examples 2025-04-03 17:10:33 +05:30
autofix-ci[bot]
5b7c1aad9e [autofix.ci] apply automated fixes 2025-04-03 10:53:10 +00:00
Sidharth Vinod
865c453547 feat: Add title and examples for diagrams 2025-04-03 16:16:44 +05:30
Sidharth Vinod
c0b14021b7 feat: Add support for examples in diagram definition 2025-04-03 11:15:45 +05:30
Shahir Ahmed
2798e27b1e dynamically resizes horizontal xychart bar
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-04-02 23:00:12 -04:00
Shahir Ahmed
f4c08a0c6f dynamically resizes vertical xychart bar
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-04-02 22:25:34 -04:00
Monica Nguyen
c28c05780c Merge branch 'mermaid-js:develop' into monica_branch 2025-04-02 17:39:11 -04:00
Shahir Ahmed
6a538da07d Merge branch 'develop' into feature/5806_xy-chart-data-labels 2025-04-02 17:22:13 -04:00
Shahir Ahmed
b2dfa74865 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-04-02 17:19:44 -04:00
Shahir Ahmed
930e917215 Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-04-02 17:18:45 -04:00
megantriplett
c8e87b113b Merge branch 'Megan3250' of https://github.com/Shahir-47/mermaid into Megan3250 2025-04-02 17:17:32 -04:00
Megan Triplett
8627fb0f62 Merge branch 'mermaid-js:develop' into Megan3250 2025-04-02 17:16:50 -04:00
Thomas Di Cizerone
cdbd3e58a3 🆙 Run pnpm changeset 2025-04-02 18:50:20 +02:00
Thomas Di Cizerone
630c4d6954 🤏 Update Note comment 2025-04-02 18:50:20 +02:00
Thomas Di Cizerone
fd4493733f Add TODO for architecture support of title embedded in render 2025-04-02 18:50:20 +02:00
Thomas Di Cizerone
e588743bf4 ⚗️ Add unit tests and e2e for architecture diagram with titleAndAccessibilities 2025-04-02 18:50:20 +02:00
Thomas Di Cizerone
04d68e7f9a ⚗️ Add parser tests for architecture and other edge cases encountered 2025-04-02 18:50:20 +02:00
Thomas Di Cizerone
9795b6e089 🖋️ Refactor common grammar to avoid unwanted greedy terminals 2025-04-02 18:50:20 +02:00
Sidharth Vinod
a9be1a4146 Merge pull request #6398 from mermaid-js/update-content
DOCS: update promo bar content
2025-04-02 02:22:53 -07:00
Steph
617c7393bf update logic 2025-04-01 23:41:43 -07:00
Ashish Jain
ceb8d4c7ef Merge pull request #6445 from mermaid-js/omkarht/chore/downgrade-chokidar-to-3.6.0
chore: Downgrade chokidar to 3.6.0 for hot reloading fix
2025-04-01 12:43:53 +00:00
omkarht
32c70a0f6a chore: Downgrade chokidar to 3.6.0 for hot reloading fix 2025-03-31 20:38:12 +05:30
Knut Sveidqvist
af2632f14a Merge pull request #6442 from mermaid-js/renovate/major-eslint
chore(deps): update dependency eslint-plugin-unicorn to v58
2025-03-31 07:33:19 +00:00
renovate[bot]
8f89ba1930 chore(deps): update dependency eslint-plugin-unicorn to v58 2025-03-31 01:56:12 +00:00
megantriplett
c1db4f2ed0 Moved text to bottom of graph, even when rows are added/deleted 2025-03-28 16:08:44 -04:00
Shahir Ahmed
ad6f855f5e adds dynamic text adjustment
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-28 16:04:51 -04:00
Shahir Ahmed
f2f2a1d275 adds test and horizontal support
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-27 23:09:27 -04:00
Shahir Ahmed
17fcf43cdb fix typo
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-27 22:14:07 -04:00
Monica Nguyen
4fff67e4af Merge branch 'mermaid-js:develop' into monica_branch 2025-03-27 22:08:09 -04:00
nghtlinh
350543a5e2 Created a new tag Special working similar as Milestone but draw a line 2025-03-27 21:51:57 -04:00
Shahir Ahmed
99a2dc7c1f adds label data to bar chart
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-27 21:51:21 -04:00
Shahir Ahmed
34e756fde6 add label config
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-27 20:32:35 -04:00
Shahir Ahmed
f74fad057a Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-03-27 20:16:45 -04:00
Shahir Ahmed
32ea973b12 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-03-27 20:14:13 -04:00
isaiah robinson
0104d19f66 Fix formatting of ELK example in ERD + clarify usage 2025-03-27 15:47:43 -07:00
megantriplett
e8986eb546 Removed previous x movement for vert and moved text down (not exactly at bottom yet) 2025-03-26 18:37:09 -04:00
Ashish Jain
936d1074b2 Merge pull request #6413 from mermaid-js/master
Merge back v11.6.0 to develop
2025-03-25 12:51:55 +00:00
Ashish Jain
7b2083926d Merge pull request #6412 from mermaid-js/changeset-release/master
Version Packages
2025-03-25 12:42:47 +01:00
github-actions[bot]
bb9210c55e Version Packages 2025-03-25 11:37:21 +00:00
Ashish Jain
16d9b63457 Add missing changeset for requirement diagram fix 2025-03-25 12:35:21 +01:00
Ashish Jain
bf3370fa5b Merge pull request #6409 from mermaid-js/release/11.6.0
Release/11.6.0
2025-03-25 11:51:37 +01:00
Ashish Jain
9f9091e5e4 Update mermaid version palceholder 2025-03-25 11:20:09 +01:00
Ashish Jain
d1b1a67d99 Merge pull request #6410 from aloisklink/test/fix-cypress-on-nodejs-v20.19.0
test(e2e): fix Cypress config for Node.JS v20.19.0
2025-03-25 09:55:42 +00:00
Alois Klink
ac625bdc7f test(e2e): fix Cypress config for Node.JS v20.19.0
Node.JS v20.19.0 breaks `import '@cypress/code-coverage/task'` in the
`cypress.config.ts` for some reason (this is probably due to the new
`experimental-require-module` feature that is enabled by default in
Node.JS v20.19.0).

As a work-around, we can change this to
`@cypress/code-coverage/task.js`.

See: https://github.com/cypress-io/code-coverage/pull/940
See: https://nodejs.org/en/blog/release/v20.19.0
2025-03-25 18:28:13 +09:00
Ashish Jain
40b85c3bbf Merge pull request #6408 from mermaid-js/fix/6193-curve-interpolation
fix: restore curve type configuration functionality for flowcharts
2025-03-24 22:34:09 +01:00
Ashish Jain
f8e329f890 Merge branch 'develop' into fix/6193-curve-interpolation 2025-03-24 21:21:11 +01:00
Ashish Jain
9b9cec9809 Merge pull request #6386 from bollwyvl/patch-5
Move requirements containment arrow to edge start
2025-03-24 02:13:53 +01:00
Ashish Jain
ad653138e1 fix: restore curve type configuration functionality for flowcharts (#6193) 2025-03-24 00:25:03 +01:00
megantriplett
a401a4ab49 Made vert render a vertical line 2025-03-21 15:39:38 -04:00
megantriplett
2bc3a0f97c vert is now a copy of milestone tag 2025-03-21 15:28:34 -04:00
Ashish Jain
f5f3b08f12 Merge pull request #6381 from thomascizeron/feat/2280_radarDiagram
feat: Add radar diagram
2025-03-21 12:37:37 +01:00
Steph
ce68da3fee update promo bar content 2025-03-20 20:11:59 -07:00
Shahir Ahmed
f7e31a978b update docs
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-19 23:44:21 -04:00
Shahir Ahmed
2d583b186d fix some pixel issues
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-19 22:51:02 -04:00
Shahir Ahmed
b322392f97 refactor tests
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-19 21:18:45 -04:00
Shahir Ahmed
573b6d9ba7 remove redundant test
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-19 20:58:17 -04:00
Shahir Ahmed
ea39254556 ensure maxLabelWidth is a number
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-19 20:41:43 -04:00
Shahir Ahmed
044a3d9686 Set legend width baseline (conf.leftMargin) and expand dynamically
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-19 20:34:44 -04:00
autofix-ci[bot]
f28f7b713d [autofix.ci] apply automated fixes 2025-03-18 23:58:40 +00:00
Regis Bittencourt
cfbd05515e Remove duplicates in integrations-community.md 2025-03-18 20:53:19 -03:00
megantriplett
1125f5a283 added new tag "vert" in ganttDB 2025-03-18 16:10:16 -04:00
Steph
fa4d4806fa update button text 2025-03-18 13:08:12 -07:00
Shahir Ahmed
20927a1c8e remove max and min attributes for maxLabelWidth
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-18 15:39:58 -04:00
pranavm2109
b2ab34ca2b fixed linting issue
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-03-18 15:36:50 -04:00
Shahir Ahmed
55e1dd0ead implemented knuth-plass line-breaking algorithm
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-03-18 15:32:04 -04:00
Shahir Ahmed
a403f78168 Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-03-18 15:17:45 -04:00
Shahir Ahmed
6c45aa3602 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-03-18 15:15:45 -04:00
Nicholas Bollweg
85ce310884 rework contains geometry to avoid clipping 2025-03-17 16:36:46 -05:00
Nicholas Bollweg
fac570cb8c try arrowhead 2025-03-17 15:43:57 -05:00
Nicholas Bollweg
a7bcd7dee5 #6380: move requirements containment arrow to start 2025-03-17 15:32:52 -05:00
autofix-ci[bot]
91bcd2da8c [autofix.ci] apply automated fixes 2025-03-17 11:16:26 +00:00
sue
ec2330875e 6382 - fix error on classDiagram.md
Fixing the error on the beginner's full action example in the class
diagram's documentation

Error: Error: Parse error on line 23:
...      callback Duck callback "Tooltip"
-----------------------^
Expecting 'NEWLINE', 'EOF', 'SQS', 'STR', 'DOT', 'GENERICTYPE', 'LABEL', 'STRUCT_START', 'STRUCT_STOP', 'STYLE_SEPARATOR', 'ANNOTATION_END', 'ALPHA', 'AGGREGATION', 'EXTENSION', 'COMPOSITION', 'DEPENDENCY', 'LOLLIPOP', 'LINE', 'DOTTED_LINE', 'CALLBACK_NAME', 'HREF', 'NUM', 'MINUS', 'UNICODE_TEXT', 'BQUOTE_STR', got 'CALLBACK'
2025-03-17 12:11:16 +01:00
Thomas Di Cizerone
bb5a7a585e ⚗️ Add radar renderer tests 2025-03-16 22:04:30 +01:00
Thomas Di Cizerone
5d1b27132a 🩹 Fix: text-color ➙ color 2025-03-16 19:00:25 +01:00
autofix-ci[bot]
288abd01e0 [autofix.ci] apply automated fixes 2025-03-16 17:46:44 +00:00
Thomas Di Cizerone
95d73bc3f0 🆙 Run pnpm changeset 2025-03-16 18:41:43 +01:00
Thomas Di Cizerone
0f5125b5e3 🖼️ Add Radar Demo with custom opacity 2025-03-16 18:34:00 +01:00
Thomas Di Cizerone
12c120368d 📚 Add documentation 2025-03-16 18:20:03 +01:00
Thomas Di Cizerone
a7f2c0bc34 🖼️ Add Radar Demo 2025-03-16 18:20:03 +01:00
Thomas Di Cizerone
5e97b2f764 ⚗️ Add Cypress test 2025-03-16 18:19:54 +01:00
Thomas Di Cizerone
d53c66dde5 🎨 Add themes for radar 2025-03-16 18:15:30 +01:00
Thomas Di Cizerone
1fb91d14c9 📊 Add radar chart 2025-03-16 18:13:50 +01:00
Thomas Di Cizerone
d80cc38bb2 🖋️ Add grammar for Radar chart 2025-03-16 18:00:50 +01:00
Ashish Jain
d6022408a9 Merge pull request #6375 from mermaid-js/master
Merge back v11.5.0 back to develop
2025-03-13 11:37:53 +01:00
Ashish Jain
41a737f682 Merge pull request #6374 from mermaid-js/changeset-release/master
Version Packages
2025-03-13 11:32:55 +01:00
github-actions[bot]
0c2e1bc3fe Version Packages 2025-03-13 10:24:33 +00:00
Ashish Jain
f399561565 Merge pull request #6373 from mermaid-js/release/11.5.0
Release/11.5.0
2025-03-13 11:22:21 +01:00
Ashish Jain
05bdf0e20e Added changeset 2025-03-13 11:16:54 +01:00
Ashish Jain
292cd83439 Fix for multi-line row issue and failsafe for edge style for stroke not present 2025-03-13 00:28:03 +01:00
Ashish Jain
3848649bdd Merge develop into release/11.5.0 2025-03-12 13:40:16 +01:00
Ashish Jain
1341e3d156 Added support for row odd/even in different themes 2025-03-12 13:13:13 +01:00
Ashish Jain
1d6a55a311 Merge pull request #6371 from mermaid-js/6369-mirror-edge-color-on-arrowhead
6369 mirror edge color on arrowhead
2025-03-12 11:36:55 +01:00
Knut Sveidqvist
4d25caba8e Added changeset 2025-03-12 10:52:17 +01:00
Knut Sveidqvist
f6335571cc test: Add test for edge marker color rendering 2025-03-12 10:45:26 +01:00
Knut Sveidqvist
bb895d8cf4 #6369 feat: Edge marker rendering applying stroke color to arrow head 2025-03-12 10:42:22 +01:00
Steph
c8f01b14a8 update links 2025-03-11 13:21:07 -07:00
autofix-ci[bot]
cdaea58096 [autofix.ci] apply automated fixes 2025-03-11 13:31:24 +00:00
Baraka Kinywa
b3d8fa917f docs(integrations): add tiki to community list cms/ecm 2025-03-11 16:26:34 +03:00
Steph
91931531a6 update link 2025-03-06 11:48:17 -08:00
Steph
50e4641666 minor updates 2025-03-05 22:26:12 -08:00
Steph
1bed6432ac update styling and add assets 2025-03-05 21:24:38 -08:00
autofix-ci[bot]
ee5dc5ae80 [autofix.ci] apply automated fixes 2025-03-03 10:25:08 +00:00
IceFreez3r
b7940b64cd Fix parameter heading level
The "Parameters" sections belong to "Icon Shape" and "Image Shape" respectively and should therefore have one more level than them.
2025-03-03 11:16:33 +01:00
Jesse Wright
1ddaf10b89 chore: create changeset 2025-03-02 22:34:55 +00:00
Jesse Wright
02b833f251 chore: remove hash and semicolon ignore 2025-03-02 22:17:21 +00:00
Jesse Wright
0ce0c3cd75 fix: allow colons in events 2025-03-02 22:04:12 +00:00
Yari DeWalt
00ca7ac94f Merge branch 'develop' into update-er-diagram 2025-02-28 11:09:53 -08:00
yari-dewalt
34cd280ae4 Merge branch 'update-er-diagram' of github.com:yari-dewalt/mermaid into update-er-diagram 2025-02-28 11:06:40 -08:00
yari-dewalt
d0986ace8c Fix styling of erBox rows 2025-02-28 11:05:16 -08:00
Steph
11f7f426cb verbiage updates 2025-02-28 08:05:42 -08:00
saurabhg772244
a31adc63a9 Updated docs and e2e test case 2025-02-28 19:09:21 +05:30
Sidharth Vinod
bc2bd3d769 Merge pull request #6333 from tommoor/patch-2
Added Outline (getoutline.com) to community integrations
2025-02-28 11:23:34 +00:00
autofix-ci[bot]
f047b81bb9 [autofix.ci] apply automated fixes 2025-02-27 22:36:17 +00:00
Tom Moor
7db1d672a9 Update Outline link in integrations-community.md 2025-02-27 14:31:29 -08:00
Shahir Ahmed
91e2c04e56 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-02-27 15:33:52 -05:00
Shahir Ahmed
a2f0d8e4d6 Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-02-27 15:32:51 -05:00
Sidharth Vinod
00a8dc47f5 Merge pull request #6320 from mermaid-js/renovate/patch-dompurify
fix(deps): update dependency dompurify to ^3.2.4
2025-02-27 17:28:56 +00:00
autofix-ci[bot]
5caaf36a3b [autofix.ci] apply automated fixes 2025-02-26 17:24:28 +00:00
yari-dewalt
4128197468 Remove to update to .ts 2025-02-26 09:19:30 -08:00
yari-dewalt
40494b16f5 Update labelBkg styles and dasharray for edges 2025-02-26 09:10:53 -08:00
yari-dewalt
840a197044 Fix syntax error 2025-02-26 08:45:12 -08:00
Yari DeWalt
ae0fcbfb8b Merge branch 'develop' into update-er-diagram 2025-02-26 08:23:04 -08:00
autofix-ci[bot]
f60ecfc2c4 [autofix.ci] apply automated fixes 2025-02-26 13:26:09 +00:00
autofix-ci[bot]
a38a0ab869 [autofix.ci] apply automated fixes 2025-02-26 13:22:02 +00:00
Saurabh Gore
06877dcc47 Update cypress/platform/viewer.js
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-02-26 18:48:27 +05:30
Saurabh Gore
050fbd9da2 Update packages/mermaid/src/docs/syntax/flowchart.md
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-02-26 18:47:29 +05:30
Tom Moor
1b5672e73d Added Outline (getoutline.com) to community integrations
Outline has full support for Mermaid diagrams including collaborative realtime editing and inline previews.

Docs:
https://docs.getoutline.com/s/guide/doc/diagrams-KQiKoT4wzK
2025-02-26 05:15:56 -08:00
Saurabh Gore
1be1e34e72 Update packages/mermaid/src/docs/syntax/flowchart.md
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-02-26 18:45:13 +05:30
Sidharth Vinod
b22103b769 Merge pull request #6331 from mermaid-js/fix-promo
DOCS: fix promo bar
2025-02-26 13:39:27 +01:00
Sidharth Vinod
9e29fd0c4a Merge branch 'develop' into sidv/stateDB-ts 2025-02-26 13:37:43 +01:00
Sidharth Vinod
a2650adec2 chore: Remove ! in datafetcher
Co-authored-by: Saurabh Gore <167211619+saurabhg772244@users.noreply.github.com>
2025-02-26 18:07:10 +05:30
renovate[bot]
33f9d8bdc9 fix(deps): update dependency dompurify to ^3.2.4 2025-02-26 11:59:12 +00:00
Ashish Jain
446f6a7701 Merge pull request #6329 from yari-dewalt/fix/could_not_find_a_suitable_point_for_the_given_distance
Fix: Could not find a suitable point for the given distance
2025-02-26 12:57:48 +01:00
Ashish Jain
2ace92858f Merge pull request #6219 from yari-dewalt/update-requirement-diagram
Update Requirement diagram to unified renderer
2025-02-26 12:52:24 +01:00
saurabhg772244
b0c1460940 Convert Font Awesome loading from HTML to JS 2025-02-26 12:55:01 +05:30
Steph
510fd0fe71 update styling 2025-02-25 21:57:38 -08:00
Steph
9268cc2e07 fix promo bar 2025-02-25 21:37:38 -08:00
Shahir Ahmed
7c7fd4bc5e adds test for line wrapping
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-25 18:40:27 -05:00
pranavm2109
baa261fdd1 Merge branch 'bug/5955_adjust-diagram-position-with-legend-width' of https://github.com/SeniorSeniorMath-SciLib2k24/mermaid into bug/5955_adjust-diagram-position-with-legend-width 2025-02-25 16:13:28 -05:00
pranavm2109
aaf15fccc1 added first draft of test to see if label text is being wrapped in different lines
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-25 16:13:14 -05:00
autofix-ci[bot]
3724d11255 [autofix.ci] apply automated fixes 2025-02-25 20:55:26 +00:00
pranavm2109
5510f18d33 removed function to get rem in px since config schema now has maxLabelWidth
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-25 15:50:10 -05:00
Shahir Ahmed
edbf125c83 wraps long text into new line
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-25 15:43:00 -05:00
pranavm2109
ad6248147c revised current cypress test
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-25 15:29:29 -05:00
Shahir Ahmed
d47e4724cb wraps long text into new line
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-25 15:21:08 -05:00
Shahir Ahmed
4f592115e0 Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-02-25 15:09:56 -05:00
Shahir Ahmed
d2d78a5576 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-02-25 15:07:54 -05:00
autofix-ci[bot]
5447a9f4f9 [autofix.ci] apply automated fixes 2025-02-25 18:23:48 +00:00
yari-dewalt
dc698c0309 Merge branch 'develop' of github.com:yari-dewalt/mermaid into fix/could_not_find_a_suitable_point_for_the_given_distance 2025-02-25 10:12:43 -08:00
yari-dewalt
31665fbad8 Fix division by zero error giving invalid point 2025-02-25 10:12:00 -08:00
Sidharth Vinod
a5561b9be0 Merge branch 'develop' into update-er-diagram 2025-02-25 15:32:46 +01:00
saurabhg772244
e045e0b42d Code refactor and updated docs 2025-02-25 18:25:59 +05:30
Sidharth Vinod
60db05b75c Merge branch 'master' into develop
* master:
  Reduced number of free trial from 14 to 7 day
  additional updates
  update urls
  [autofix.ci] apply automated fixes
  Update diagram limit
  remove unused import
  additional updates
  additional changes
  update styling
  wip
  update to five second interval
  Revert lock file changes
  Delete pnpm-lock.yaml
  [autofix.ci] apply automated fixes
  add new blog posts
  update Discord links
2025-02-25 08:26:14 +05:30
Sidharth Vinod
3be59a7b4d Merge pull request #6318 from mermaid-js/renovate/patch-eslint
chore(deps): update eslint (patch)
2025-02-24 03:40:50 +00:00
Sidharth Vinod
ff00141a0a Merge pull request #6319 from mermaid-js/renovate/patch-all-patch
fix(deps): update all patch dependencies (patch)
2025-02-24 03:40:14 +00:00
autofix-ci[bot]
374ebbb087 [autofix.ci] apply automated fixes 2025-02-24 01:57:21 +00:00
renovate[bot]
9d06d8f31e fix(deps): update all patch dependencies 2025-02-24 01:52:02 +00:00
renovate[bot]
97b12e9718 chore(deps): update eslint 2025-02-24 01:51:31 +00:00
Shahir Ahmed
50816a7f98 remove magic value
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-21 17:35:32 -05:00
Shahir Ahmed
a318ea3692 removes cy.then and magic value
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-21 16:15:24 -05:00
Shahir Ahmed
1424127127 Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-02-21 15:33:13 -05:00
Shahir Ahmed
9c27125f2d changes default values
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-21 15:27:01 -05:00
Shahir Ahmed
6140be24da Merge branch 'develop' into feature/3508_color-user-journey-title 2025-02-21 15:04:12 -05:00
Sidharth Vinod
de40d80ef9 fix: Create PR for E2E timings, as push to develop fails 2025-02-21 23:56:46 +05:30
Sidharth Vinod
c9b8f034d5 Merge pull request #5841 from mermaid-js/renovate/major-all-major
fix(deps): update all major dependencies (major)
2025-02-21 23:53:35 +05:30
saurabhg772244
2fb7bc2806 fix pnpm lock and use promise.all to speed up icon replacement 2025-02-21 23:45:33 +05:30
Sidharth Vinod
162e9e50ad Merge branch 'renovate/major-all-major' of https://github.com/mermaid-js/mermaid into renovate/major-all-major
* 'renovate/major-all-major' of https://github.com/mermaid-js/mermaid:
  [autofix.ci] apply automated fixes
2025-02-21 23:44:22 +05:30
Sidharth Vinod
225e5dde60 fix: Add clearMocks in vitest 2025-02-21 23:44:09 +05:30
autofix-ci[bot]
726b42ba00 [autofix.ci] apply automated fixes 2025-02-21 18:05:57 +00:00
Sidharth Vinod
c22b5701db chore: Fix types 2025-02-21 23:30:34 +05:30
renovate[bot]
c6b715f737 fix(deps): update all major dependencies 2025-02-21 17:50:49 +00:00
Sidharth Vinod
bc69180958 Merge pull request #5839 from mermaid-js/renovate/all-minor
fix(deps): update all minor dependencies (minor)
2025-02-21 23:16:16 +05:30
saurabhg772244
83a6e696c6 fix lock file 2025-02-21 23:07:25 +05:30
Sidharth Vinod
a64b14dbfd chore: bump ts-eslint version 2025-02-21 23:02:39 +05:30
saurabhg772244
a89e001d01 Merge branch 'saurabh/refactor-fontawesome-icon-usage' of github.com-mermaid:mermaid-js/mermaid into saurabh/refactor-fontawesome-icon-usage 2025-02-21 23:00:47 +05:30
saurabhg772244
6a81a907d1 Merge branch 'develop' of github.com-mermaid:mermaid-js/mermaid into saurabh/refactor-fontawesome-icon-usage 2025-02-21 23:00:33 +05:30
Sidharth Vinod
1c8b996cbb chore: Bump eslint version 2025-02-21 22:57:43 +05:30
Sidharth Vinod
eb8e4da5f6 chore: Bump package.json versions with renovate 2025-02-21 22:50:01 +05:30
saurabhg772244
16573d97f5 Updated docs, added visual regression test 2025-02-21 19:45:14 +05:30
Sidharth Vinod
2fdd24ab15 Merge branch 'develop' into renovate/all-minor
* develop:
  [autofix.ci] apply automated fixes
  chore(deps): update eslint
2025-02-21 16:33:51 +05:30
autofix-ci[bot]
c01aee842a [autofix.ci] apply automated fixes 2025-02-21 10:37:37 +00:00
Sidharth Vinod
2c22e80dba chore: Update typedoc-plugin-markdown 2025-02-21 16:02:03 +05:30
Sidharth Vinod
0518e9cfd7 Merge pull request #5984 from mermaid-js/renovate/eslint
chore(deps): update eslint (minor)
2025-02-21 10:26:12 +00:00
Sidharth Vinod
fe2e73ed94 Merge pull request #6311 from yogitas-ht/Reduced-the-number-of-free-trial-from-14-to-7-days
Reduced number of free trial from 14 to 7 day
2025-02-21 14:43:27 +05:30
Sidharth Vinod
4f5c4b8349 Merge pull request #6309 from mermaid-js/promos
DOCS: TopBar updates
2025-02-21 13:43:52 +05:30
yogitas-ht
ce99d968f4 Reduced number of free trial from 14 to 7 day 2025-02-21 13:12:18 +05:30
Steph
877a7e288a additional updates 2025-02-20 11:30:07 -08:00
Steph
4eeea1076c update urls 2025-02-20 10:36:06 -08:00
autofix-ci[bot]
f43e35039f [autofix.ci] apply automated fixes 2025-02-20 18:31:20 +00:00
renovate[bot]
dbf885b077 chore(deps): update eslint 2025-02-20 18:25:55 +00:00
renovate[bot]
78c1d97f0f fix(deps): update all minor dependencies 2025-02-20 16:41:05 +00:00
Sidharth Vinod
5abda14809 Merge branch 'develop' into sidv/stateDB-ts 2025-02-20 16:31:59 +05:30
Sidharth Vinod
ad2f17205a Merge pull request #6272 from mermaid-js/saurabh/refactor/convert-sequenceDb-to-class
Refactor: Change SequenceDB to class based architecture.
2025-02-20 07:20:14 +00:00
Sidharth Vinod
bb4b92a663 fix: Type issue in getDirectionStatement 2025-02-19 18:59:30 +05:30
Sidharth Vinod
9bd599666b Merge branch 'develop' into sidv/stateDB-ts
* develop:
  chore: Remove deprecated rule
  chore(deps): update eslint
  chore: Add tslib
  chore(deps): update eslint
  chore: Minor refactor
  chore: Update actions/cache
  chore: Update actions/cache
  added changeset
  added test cases to check state diagram direction
  fix: CodeQL double escape warning
  refatored code
  chore(deps): update eslint
  Fix: state diagram default direction update
  [autofix.ci] apply automated fixes
  fix(deps): update all patch dependencies
2025-02-19 18:38:30 +05:30
autofix-ci[bot]
36894fe14a [autofix.ci] apply automated fixes 2025-02-19 10:47:08 +00:00
Gozie Joshua
efe834e772 Added class styling example to block.md 2025-02-19 11:19:24 +01:00
Sidharth Vinod
98fe7a6e03 Merge pull request #5997 from mermaid-js/renovate/major-eslint
chore(deps): update eslint (major)
2025-02-19 12:48:14 +05:30
saurabhg772244
8857e77495 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor-fontawesome-icon-usage 2025-02-19 11:35:03 +05:30
saurabhg772244
5857953d51 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-sequenceDb-to-class 2025-02-19 11:26:22 +05:30
Shahir Ahmed
5dab86a067 Merge branch 'bug/5955_adjust-diagram-position-with-legend-width' of https://github.com/Shahir-47/mermaid into bug/5955_adjust-diagram-position-with-legend-width 2025-02-18 16:12:37 -05:00
Shahir Ahmed
9ef35549f4 Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-02-18 16:05:16 -05:00
pranavm2109
4beed963b8 updated descriptions of parameters in schema
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-18 16:03:12 -05:00
pranavm2109
3122c3b75c updated descriptions of parameters in schema
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-18 16:01:40 -05:00
pranavm2109
dffa689e2b updated documentation
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-18 15:58:03 -05:00
pranavm2109
5ed2278887 Merge branch 'feature/3508_color-user-journey-title' of https://github.com/SeniorSeniorMath-SciLib2k24/mermaid into feature/3508_color-user-journey-title 2025-02-18 15:36:56 -05:00
pranavm2109
d6376ca1ff Reverted to using configObject in place of conf
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-18 15:36:51 -05:00
autofix-ci[bot]
99bd0c48fa [autofix.ci] apply automated fixes 2025-02-18 20:31:21 +00:00
pranavm2109
eb7289a65a Merge branch 'feature/3508_color-user-journey-title' of https://github.com/SeniorSeniorMath-SciLib2k24/mermaid into feature/3508_color-user-journey-title 2025-02-18 15:26:10 -05:00
pranavm2109
80c6b945fa Removed title style documentation from theming.md
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-18 15:25:12 -05:00
Sidharth Vinod
34a12103d0 Merge branch 'renovate/major-eslint' of https://github.com/mermaid-js/mermaid into renovate/major-eslint
* 'renovate/major-eslint' of https://github.com/mermaid-js/mermaid:
  chore(deps): update eslint
2025-02-19 00:34:03 +05:30
Sidharth Vinod
46b8a75199 chore: Remove deprecated rule 2025-02-19 00:33:56 +05:30
renovate[bot]
1dca45a76d chore(deps): update eslint 2025-02-18 19:01:39 +00:00
Sidharth Vinod
d1d5bd14f6 Merge branch 'develop' into renovate/major-eslint
* develop:
  chore: Add tslib
  [autofix.ci] apply automated fixes
  fix(deps): update all patch dependencies
2025-02-19 00:28:32 +05:30
Sidharth Vinod
974867a089 Merge pull request #5961 from mermaid-js/renovate/patch-all-patch
fix(deps): update all patch dependencies (patch)
2025-02-19 00:24:41 +05:30
Sidharth Vinod
52532a7801 Merge pull request #6295 from mermaid-js/omkar/fix-state-diagram-default-direction
Fix: state diagram default direction update
2025-02-18 18:53:57 +00:00
Sidharth Vinod
6eb56b9363 Merge branch 'develop' into renovate/patch-all-patch
* develop: (97 commits)
  chore: Update actions/cache
  chore: Update actions/cache
  fix: CodeQL double escape warning
  chore(deps): update eslint
  Added changeset.
  refactor: handle StateDB `.extract()` properly
  chore(deps): update dependency esbuild to ^0.25.0 [security]
  Update .changeset/grumpy-cheetahs-deliver.md
  chore: Use RUN_VISUAL_TEST in cypress config
  chore: Use argos tokenless auth
  chore: Add tokenless auth to argos
  fix(deps): update dependency dompurify to v3.2.4 [security]
  chore: Update argos token
  Ignore huehive
  chore: Run argos on all PRs, except renovate bot's
  chore: Fix exclude
  [autofix.ci] apply automated fixes
  chore(deps): update dependency vitest to v1.6.1 [security]
  docs: Cleanup minor issues
  Add files via upload
  ...
2025-02-19 00:08:50 +05:30
Sidharth Vinod
f7c91a72cb chore: Add tslib 2025-02-19 00:06:45 +05:30
renovate[bot]
c53e044559 chore(deps): update eslint 2025-02-18 18:26:30 +00:00
Sidharth Vinod
d846a8c65a chore: Minor refactor 2025-02-18 23:48:19 +05:30
Sidharth Vinod
c3ba23a4e9 Merge branch 'develop' into omkar/fix-state-diagram-default-direction 2025-02-18 23:44:19 +05:30
Sidharth Vinod
c688c387a0 Merge pull request #6298 from mermaid-js/saurabh/fix/sanitizeText-codeql-warning
fix: CodeQL double escape warning
2025-02-18 23:41:31 +05:30
Sidharth Vinod
300fb85a73 chore: Update actions/cache 2025-02-18 23:41:01 +05:30
Sidharth Vinod
9c6e554153 chore: Update actions/cache 2025-02-18 23:40:53 +05:30
Sidharth Vinod
b5c78b7225 Merge pull request #5908 from mermaid-js/renovate/patch-eslint
chore(deps): update eslint (patch)
2025-02-18 21:42:23 +05:30
Sidharth Vinod
26bd8cb53c Merge pull request #6288 from mermaid-js/sidharthv96-patch-1
Update mermaidchart diagram limit
2025-02-18 21:08:44 +05:30
saurabhg772244
a81c3187ba removed font awesome packages and used registered icons instead 2025-02-18 19:53:18 +05:30
omkarht
da6361f652 added changeset 2025-02-18 18:36:52 +05:30
omkarht
167fef5cff added test cases to check state diagram direction 2025-02-18 17:23:48 +05:30
saurabhg772244
3233c63fc0 Updated variable name 2025-02-18 16:59:35 +05:30
saurabhg772244
1182aaaf4d fix: CodeQL double escape warning 2025-02-18 15:42:25 +05:30
omkarht
b78c061a8f refatored code 2025-02-18 15:40:45 +05:30
Sidharth Vinod
39a5abc714 chore: Minor refactors to stateDB 2025-02-18 13:50:49 +05:30
Sidharth Vinod
6650efc1a6 fix: Note position 2025-02-18 00:51:38 +05:30
Sidharth Vinod
a4754ad195 chore: Add changeset 2025-02-18 00:33:47 +05:30
Sidharth Vinod
91cbe5bc01 fix: StateStmt import 2025-02-18 00:29:57 +05:30
Sidharth Vinod
d2996dd553 fix: Statement handling 2025-02-18 00:23:58 +05:30
Sidharth Vinod
7a7836ad90 Merge branch 'develop' into sidv/stateDB-ts
* develop:
  Added changeset.
  refactor: handle StateDB `.extract()` properly
2025-02-17 23:50:10 +05:30
Sidharth Vinod
7ca9242b24 chore: Add types to stateDB and dataFetcher 2025-02-17 23:47:56 +05:30
renovate[bot]
ebfcf3ea07 chore(deps): update eslint 2025-02-17 15:45:31 +00:00
Sidharth Vinod
62edea6b33 Merge pull request #6293 from mermaid-js/saurabh/refactor/handle-StateDB-.extract-properly
Handle StateDB `.extract()` properly
2025-02-17 21:13:26 +05:30
omkarht
72eda9ce52 Fix: state diagram default direction update 2025-02-17 20:53:31 +05:30
saurabhg772244
cfd84e54d5 Added changeset. 2025-02-17 16:14:55 +05:30
Alois Klink
cfe710f42b refactor: handle StateDB .extract() properly
Fix the StateDB properly for stateDiagram-v1 vs stateDiagram-v2.
2025-02-17 15:54:19 +05:30
Sidharth Vinod
438f388b5c chore: Rename dataFetcher 2025-02-17 00:27:43 +05:30
Sidharth Vinod
e89c77a5ca chore: Remove id-cache 2025-02-17 00:27:02 +05:30
autofix-ci[bot]
87e76bbcf5 [autofix.ci] apply automated fixes 2025-02-15 18:26:55 +00:00
Sidharth Vinod
0b4754ed60 Update diagram limit 2025-02-15 23:51:48 +05:30
saurabhg772244
fe6f05eec9 Merge branch 'develop' of github.com-mermaid:mermaid-js/mermaid into saurabh/refactor/convert-sequenceDb-to-class 2025-02-15 22:56:53 +05:30
Sidharth Vinod
31984acfe0 chore: Rename stateDB 2025-02-15 22:52:35 +05:30
Sidharth Vinod
9badfe7489 Merge branch 'develop' into feature/3508_color-user-journey-title 2025-02-15 22:33:13 +05:30
Sidharth Vinod
548256507d Merge pull request #6269 from mermaid-js/renovate/npm-esbuild-vulnerability
chore(deps): update dependency esbuild to ^0.25.0 [security]
2025-02-15 16:51:26 +00:00
Sidharth Vinod
d8ebf7a136 Merge pull request #6250 from mermaid-js/saurabh/refactor/convert-stateDb-to-class-v2
Refactor: V2. Change StateDB to class based architecture.
2025-02-15 16:50:55 +00:00
Sidharth Vinod
27912bee8c Merge branch 'develop' into bug/5955_adjust-diagram-position-with-legend-width 2025-02-15 22:14:44 +05:30
renovate[bot]
a758b24b75 chore(deps): update dependency esbuild to ^0.25.0 [security] 2025-02-15 16:16:28 +00:00
Sidharth Vinod
3004d4d93a Merge branch 'develop' into update-requirement-diagram 2025-02-15 21:45:38 +05:30
Saurabh Gore
88abf46fc3 Update .changeset/grumpy-cheetahs-deliver.md
Co-authored-by: Sidharth Vinod <github@sidharth.dev>
2025-02-15 21:33:58 +05:30
Sidharth Vinod
2eeba0e999 Merge branch 'develop' into saurabh/refactor/convert-stateDb-to-class-v2 2025-02-15 21:31:14 +05:30
Sidharth Vinod
397684fe49 Merge pull request #6284 from mermaid-js/renovate/npm-dompurify-vulnerability
fix(deps): update dependency dompurify to v3.2.4 [security]
2025-02-15 16:00:56 +00:00
Sidharth Vinod
bc1f769f13 Merge pull request #6287 from sidharthv96/sidv/tokenlessArgos
chore: Add tokenless auth to argos
2025-02-15 21:30:39 +05:30
Sidharth Vinod
f6592235a2 chore: Use RUN_VISUAL_TEST in cypress config 2025-02-15 21:05:47 +05:30
Sidharth Vinod
57805dafa4 chore: Use argos tokenless auth 2025-02-15 20:51:56 +05:30
Sidharth Vinod
3b92f979e3 chore: Add tokenless auth to argos 2025-02-15 20:28:55 +05:30
renovate[bot]
7a7e4b4e6f fix(deps): update dependency dompurify to v3.2.4 [security] 2025-02-15 14:39:21 +00:00
Sidharth Vinod
c5843bee23 chore: Update argos token
We have added a check in e2e, to ensure events in forks will not trigger the visual tests.

This will not protect against malicious users, but there is no other way to support PRs from forks.

A proposal has been sent to Argos team to add a secure approach for public repos, fingers crossed.
2025-02-15 20:07:41 +05:30
Shahir Ahmed
7aef182fbf Merge branch 'develop' into feature/3508_color-user-journey-title 2025-02-14 16:45:20 -05:00
autofix-ci[bot]
2fb6ea7b77 [autofix.ci] apply automated fixes 2025-02-14 21:23:01 +00:00
pranavm2109
add48da4c8 modifed journey diagram config scheme to contain title specific styles, and undid previous theme-wide changes
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-14 16:17:09 -05:00
Sidharth Vinod
ada42b892c Ignore huehive 2025-02-14 21:41:53 +05:30
Sidharth Vinod
62f9261c4e Merge branch 'develop' into saurabh/refactor/convert-stateDb-to-class-v2 2025-02-14 21:21:00 +05:30
Sidharth Vinod
a19b42f3c2 Merge pull request #6283 from mermaid-js/sidv/argos-skip-renovate
Run visual test on all PRs, except renovate bot's
2025-02-14 21:20:38 +05:30
Sidharth Vinod
9f90f4f23a chore: Run argos on all PRs, except renovate bot's 2025-02-14 21:17:29 +05:30
saurabhg772244
451c886f50 Code refactor. 2025-02-14 19:17:09 +05:30
saurabhg772244
0a1a112605 Move setWrap below clear in constructor. 2025-02-14 17:51:17 +05:30
Saurabh Gore
d63d3bf1e7 added changeset 2025-02-14 16:37:41 +05:30
Saurabh Gore
33e5694a75 update styles so that proper fill is applied to icons 2025-02-14 16:32:59 +05:30
Saurabh Gore
302ba725ae embed free font awesome svg instead of i tag. pro icons will still work with i tag 2025-02-14 16:32:11 +05:30
Sidharth Vinod
63cf7cbd94 Merge pull request #6279 from mermaid-js/update-promos
DOCS: update promos
2025-02-14 13:24:07 +05:30
Steph
8ab60c3a7a remove unused import 2025-02-13 15:07:50 -08:00
Steph
0342579b9c additional updates 2025-02-13 15:05:24 -08:00
Sidharth Vinod
348401c4f4 Merge pull request #6253 from mermaid-js/renovate/npm-vitest-vulnerability
chore(deps): update dependency vitest to v1.6.1 [security]
2025-02-13 19:48:12 +00:00
Sidharth Vinod
8145199203 Merge pull request #6265 from Mandzhi/Mandzhi-patch-2
Update tutorials.md
2025-02-13 19:47:54 +00:00
Sidharth Vinod
f408e938d4 chore: Fix exclude 2025-02-14 01:01:48 +05:30
Steph
6471ae4d49 additional changes 2025-02-13 02:18:12 -08:00
autofix-ci[bot]
af6e2b4cb6 [autofix.ci] apply automated fixes 2025-02-13 08:23:14 +00:00
renovate[bot]
7a4a52b50a chore(deps): update dependency vitest to v1.6.1 [security] 2025-02-13 08:21:24 +00:00
Sidharth Vinod
ee05d8588f Merge pull request #6245 from homersimpsons/patch-1
Add git graph preview in README.md
2025-02-13 13:49:08 +05:30
Sidharth Vinod
58175f647e docs: Cleanup minor issues 2025-02-13 13:47:49 +05:30
Shahir Ahmed
5f7c68def7 refactor: standardize variable naming and improve legend width calculations
Co-authored-by: pranavm2109 <mishrap@dickinson.edu>
2025-02-13 01:46:27 -05:00
Sidharth Vinod
82d019234a chore: Cleanup 2025-02-13 09:50:04 +05:30
Shahir Ahmed
d618b8398e adds test for journey
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-12 19:54:56 -05:00
Steph
ec0e3e4cd6 update styling 2025-02-12 16:00:28 -08:00
Shahir Ahmed
db4ea020ba testing
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-12 18:39:03 -05:00
Steph
72cf84cb40 wip 2025-02-12 14:02:01 -08:00
pranavm2109
5366e8b692 added first draft of cypress visual tests
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-02-12 15:19:37 -05:00
saurabhg772244
6ca8f46d37 Updated unit tests. 2025-02-12 16:15:06 +05:30
saurabhg772244
b2dfbb6ffd Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-sequenceDb-to-class 2025-02-12 16:04:54 +05:30
saurabhg772244
ffa7804af0 added changeset 2025-02-12 16:04:22 +05:30
saurabhg772244
f454865b97 Updated unit tests to reflect new DB instance per parse. 2025-02-12 16:00:14 +05:30
saurabhg772244
d83b1a5dbc Refactored arrow function to regular function and assigned unique ID to messages during parsing. 2025-02-12 15:54:51 +05:30
Radmila M.
d07f85e6ac Add files via upload 2025-02-10 14:05:55 +03:00
Radmila M.
a79c0f4c00 Update tutorials.md 2025-02-10 14:01:09 +03:00
Radmila M.
4a19740aea Update tutorials.md 2025-02-10 13:24:38 +03:00
Shahir Ahmed
fbac4c61bb diagram adjusts with legend width changes
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-02-05 19:27:32 -05:00
saurabhg772244
4dbaa2b5d6 code refactor 2025-02-04 19:18:46 +05:30
saurabhg772244
9cad3c7aea added changeset 2025-02-04 17:09:09 +05:30
saurabhg772244
56d66cdabc Fix issue where data was not being set in the db after parsing. 2025-02-04 16:45:45 +05:30
saurabhg772244
a0e5408850 convert stateDb to class, added test case. 2025-02-04 16:41:54 +05:30
homersimpsons
d155e414a0 Add git graph preview in README.md 2025-02-01 11:20:06 +01:00
Shahir Ahmed
d81ddf246c fixes titleColor default value
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-31 17:57:25 -05:00
Shahir Ahmed
ffe1bb359f update pnpm-lock.yaml
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-31 17:30:34 -05:00
Shahir Ahmed
88a39f8e16 update dependencies for CI/CD pipeline
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-31 17:28:55 -05:00
Shahir Ahmed
9fb46ae88f improves description for user journey diagram title test
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-29 16:20:43 -05:00
Shahir Ahmed
798fb98b2a Merge branch 'develop' into feature/3508_color-user-journey-title
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-29 16:15:00 -05:00
Shahir Ahmed
7c0af381d1 adds styling, font-weight and font-family tests for user jounrey title
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-29 16:11:57 -05:00
pranavm2109
384f59eee2 called getConfig() once in draw function and used returned value elsewhere within
Co-authored-by: Shahir Ahmed <ahmeds@dickinson.edu>
2025-01-29 14:45:42 -05:00
Yari DeWalt
127390978a Merge branch 'develop' into update-er-diagram 2025-01-28 08:21:32 -08:00
Yari DeWalt
baf3adf1c0 Merge branch 'develop' into update-requirement-diagram 2025-01-28 08:21:27 -08:00
yari-dewalt
d0768cbc37 Update shape 2025-01-28 08:10:07 -08:00
yari-dewalt
f00507449b Remove unnecessary default export 2025-01-28 07:51:06 -08:00
yari-dewalt
509793d5c2 Remove unnecessary default export 2025-01-28 07:48:51 -08:00
Ashish Jain
8dd0e7a794 Merge pull request #6229 from mermaid-js/patch/font-family-legend-user-diagram
Set custom font family for legend in user diagrams.
2025-01-28 10:30:20 +01:00
yari-dewalt
8a8d169e27 Fix typo 2025-01-27 10:36:28 -08:00
yari-dewalt
b53cf0a1fb Fix getConfig to return correct config 2025-01-27 10:33:45 -08:00
yari-dewalt
58fa99787c Merge branch 'update-er-diagram' of github.com:yari-dewalt/mermaid into update-er-diagram 2025-01-27 10:32:17 -08:00
yari-dewalt
1a9a9f43e6 Update erDb to use class to wrap data 2025-01-27 10:31:47 -08:00
yari-dewalt
aeec4b7f77 Fix non-htmlLabels not being centered 2025-01-27 10:28:59 -08:00
autofix-ci[bot]
40686f198c [autofix.ci] apply automated fixes 2025-01-27 18:01:00 +00:00
Yari DeWalt
295af02744 Merge branch 'develop' into update-er-diagram 2025-01-27 09:55:30 -08:00
yari-dewalt
a3f35f6367 Fix parser test file 2025-01-27 09:40:09 -08:00
yari-dewalt
523286bbcb Update test file to work with new Db 2025-01-27 09:29:51 -08:00
yari-dewalt
c296f48ebe Merge branch 'update-requirement-diagram' of github.com:yari-dewalt/mermaid into update-requirement-diagram 2025-01-27 09:22:24 -08:00
yari-dewalt
9609aced14 Update requirementDb to class to encapsulate data 2025-01-27 09:21:34 -08:00
yari-dewalt
97788df7e3 Change variable casing 2025-01-27 08:21:52 -08:00
yari-dewalt
47d4d56fa6 Remove -unified from renderer file name 2025-01-27 07:14:10 -08:00
saurabhg772244
5e9c887385 Fixed unit tests. 2025-01-27 16:30:35 +05:30
saurabhg772244
fdb8ae5b53 Set custom font family for legend in user diagrams. 2025-01-27 16:16:43 +05:30
Sidharth Vinod
65ff22d94b Merge pull request #6227 from mermaid-js/update-promo-bar
Promo bar update
2025-01-27 12:25:42 +05:30
Steph
5cf093ca9e update to five second interval 2025-01-26 18:26:54 -08:00
Shahir Ahmed
03ff28e927 removes console.warn()
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-25 22:12:16 -05:00
Shahir Ahmed
16a1a90705 adds font family and font size to the title of the user journey diagram
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-25 22:01:30 -05:00
Shahir Ahmed
3221cbfa0a add titleColor theme variable to theming.md
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-25 21:23:35 -05:00
Shahir Ahmed
f0a8ccb177 Merge branch 'develop' into feature/3508_color-user-journey-title
Co-authored-by: Pranav Mishra <mishrap@dickinson.edu>
2025-01-25 21:12:11 -05:00
Shahir Ahmed
a30705cdcc Enhance user journey diagram title color configuration 2025-01-25 20:33:39 -05:00
Sidharth Vinod
e2de55202f Merge pull request #6224 from theHacker/patch-1
Fix: Wrong link to d3-shape documentation in Flowchart docs
2025-01-26 00:40:08 +05:30
autofix-ci[bot]
b4043840ca [autofix.ci] apply automated fixes 2025-01-25 12:03:03 +00:00
Alexander Münch
8f3e17e386 Fix: Wrong link to d3-shape documentation in Flowchart docs 2025-01-25 12:47:59 +01:00
Sidharth Vinod
4e950e7256 Merge pull request #6177 from Ryuno-Ki/forgejo-integration
docs: add Forgejo as integration
2025-01-25 16:24:52 +05:30
autofix-ci[bot]
de3e381ccf [autofix.ci] apply automated fixes 2025-01-25 10:41:45 +00:00
Sidharth Vinod
b2fde76753 Add Forgejo to cspell 2025-01-25 16:06:46 +05:30
Sidharth Vinod
b5587d8b87 test: Fix duplicate test name 2025-01-25 15:45:42 +05:30
André Jaenisch
9b75aeb224 Update integrations-community.md
Added Forgejo as integration
2025-01-25 10:22:35 +01:00
André Jaenisch
993858cdc8 Merge branch 'mermaid-js:develop' into forgejo-integration 2025-01-25 10:20:39 +01:00
Sidharth Vinod
f4e1f07412 chore: Update mermaid repo link to mermaid-js/mermaid
https://github.com/mermaid-js/mermaid/actions/runs/12963524805/job/36161210394
2025-01-25 14:31:24 +05:30
Sidharth Vinod
09e0de6053 chore: Update upload-artifact to v4
Verified that the other hash was infact valid and in the repo, but the scorecard action was not picking it up.
2025-01-25 14:27:18 +05:30
Sidharth Vinod
9a50bf5237 chore: Fix cypress record flag 2025-01-25 14:21:11 +05:30
Sidharth Vinod
5747009c8f chore: Fix failing tests 2025-01-25 14:09:09 +05:30
Sidharth Vinod
dc513ec211 Merge pull request #6098 from royaljain/feature/mermaid-ai-bot
Add Mermaid AI Bot in Readme
2025-01-25 12:18:07 +05:30
Sidharth Vinod
5f58d4f7b0 Merge pull request #6106 from zackkatz/patch-1
Youtube --> YouTube
2025-01-25 12:14:53 +05:30
Sidharth Vinod
3536ceb5d3 Merge branch 'develop' into patch-1 2025-01-25 12:14:31 +05:30
Sidharth Vinod
7ed33a91c0 Merge pull request #6183 from mermaid-js/renovate/autofix-ci-action-digest
chore(deps): update autofix-ci/action digest to 551dded
2025-01-25 12:13:59 +05:30
Sidharth Vinod
f8bf03d365 Merge pull request #6180 from mermaid-js/renovate/actions-upload-artifact-digest
chore(deps): update actions/upload-artifact digest to ff15f03
2025-01-25 12:13:41 +05:30
Sidharth Vinod
4202ee521a Merge pull request #6209 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v5.4.12 [security]
2025-01-25 12:12:52 +05:30
renovate[bot]
0e25fd42f9 chore(deps): update autofix-ci/action digest to 551dded 2025-01-25 06:42:31 +00:00
renovate[bot]
feee5d1c8c chore(deps): update actions/upload-artifact digest to ff15f03 2025-01-25 06:42:28 +00:00
renovate[bot]
ab6d92c544 chore(deps): update dependency vite to v5.4.12 [security] 2025-01-25 06:41:59 +00:00
Sidharth Vinod
d27d4abab7 Merge pull request #6181 from politbuero-kampagnen/patch-2
Update integrations-community.md
2025-01-25 12:10:34 +05:30
Sidharth Vinod
3162cff7a9 Merge branch 'develop' into forgejo-integration 2025-01-25 12:03:20 +05:30
Sidharth Vinod
74edf7a027 Merge branch 'develop' into update-requirement-diagram 2025-01-25 11:48:48 +05:30
Sidharth Vinod
9681a27b31 chore: Skip running E2E on comments without visual test command 2025-01-25 11:48:26 +05:30
Sidharth Vinod
22091f6182 Merge branch 'develop' into update-requirement-diagram 2025-01-25 11:35:48 +05:30
Sidharth Vinod
ba534985ec Merge pull request #6222 from mermaid-js/sidv/visualTestComment
chore: Add a command to execute visual test
2025-01-25 11:34:09 +05:30
Sidharth Vinod
edc1ae1e0c chore: Update default values 2025-01-25 11:23:30 +05:30
Sidharth Vinod
c00f3fb090 chore: Add a command to execute visual test 2025-01-25 11:01:23 +05:30
yari-dewalt
23bc25ef94 Merge branch 'update-requirement-diagram' of github.com:yari-dewalt/mermaid into update-requirement-diagram 2025-01-24 10:52:37 -08:00
yari-dewalt
42dfa20fd4 Remove old requirement diagram files 2025-01-24 10:52:15 -08:00
Yari DeWalt
cc2373ea89 Merge branch 'develop' into update-requirement-diagram 2025-01-24 10:43:23 -08:00
yari-dewalt
22bc234ff3 Update documentation to include new changes 2025-01-24 10:24:41 -08:00
yari-dewalt
fa48f9580f Add e2e tests 2025-01-24 09:42:37 -08:00
yari-dewalt
38ca14da43 Fix non-htmlLabel text replacement so markdown styling remains 2025-01-24 09:40:00 -08:00
Ashish Jain
74a56fc58a Merge pull request #6218 from mermaid-js/revert-state-diagram-class-architecture
Revert state diagram class based architecture
2025-01-24 15:09:54 +01:00
Saurabh Gore
08ffbb61e9 remove unused import 2025-01-24 19:32:17 +05:30
Saurabh Gore
232e60c8cb Added changeset 2025-01-24 19:25:44 +05:30
Saurabh Gore
cd9ca76e39 Revert state diagram class based architecture 2025-01-24 19:20:40 +05:30
Ashish Jain
c13d988392 Merge pull request #6212 from mermaid-js/saurabh/refactor/convert-classDb-to-class
Refactor: Change ClassDB to class based architecture.
2025-01-24 12:28:20 +01:00
saurabhg772244
15ffe2021a Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-classDb-to-class 2025-01-24 16:48:22 +05:30
Ashish Jain
4fbc19e0d7 Merge pull request #6185 from mermaid-js/saurabh/refactor/convert-stateDb-to-class
Refactor: Change StateDB to class based architecture.
2025-01-24 10:46:42 +01:00
yari-dewalt
02f661a103 Update and add tests 2025-01-23 12:04:04 -08:00
yari-dewalt
130638f6e1 Change requirement_id to requirementId 2025-01-23 10:57:11 -08:00
yari-dewalt
9ab2761c1d Make undefined text not display 2025-01-23 10:55:14 -08:00
yari-dewalt
41d7a549b0 Add support for classes 2025-01-23 09:36:49 -08:00
saurabhg772244
2b8998fdd1 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-classDb-to-class 2025-01-23 14:59:41 +05:30
saurabhg772244
202ef31071 Fixed binding issue 2025-01-23 14:58:16 +05:30
saurabhg772244
b09f2e836a Updated as per PR comments 2025-01-23 12:25:38 +05:30
saurabhg772244
6a814a0d91 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-stateDb-to-class 2025-01-23 11:53:01 +05:30
saurabhg772244
b07bb9b3ff Minor change 2025-01-23 11:44:06 +05:30
Ashish Jain
5120ed09ab Merge pull request #6161 from mermaid-js/saurabh/refactor/convert-flowDb-to-class
Refactor: Change flowDB to class based architecture.
2025-01-22 22:41:52 +01:00
yari-dewalt
081681f05b Add styling support for requirement diagram and box shape 2025-01-22 11:07:15 -08:00
yari-dewalt
f7648e85d9 Add support for direction statement 2025-01-22 09:00:48 -08:00
yari-dewalt
fe833e6d16 Fix elements not showing up if they were involved in a relation 2025-01-22 08:49:01 -08:00
yari-dewalt
809f4eb609 Send all edge data and add markers 2025-01-22 08:16:18 -08:00
saurabhg772244
61f3fc5ede Use static reference for relationType in StateDB 2025-01-22 19:17:38 +05:30
saurabhg772244
90bbf90a83 Added changeset 2025-01-22 19:10:48 +05:30
saurabhg772244
92efc24283 Refactored arrow functions to standard function 2025-01-22 19:07:53 +05:30
saurabhg772244
1c45df4567 Updated as per PR comments 2025-01-22 17:53:51 +05:30
saurabhg772244
1575a93136 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-flowDb-to-class 2025-01-22 16:22:20 +05:30
saurabhg772244
bde653b1c2 Updated as per Alois suggestion 2025-01-22 15:49:51 +05:30
Ashish Jain
e9e663ffa3 Merge pull request #6198 from mermaid-js/edge-flicker-fix
edge flickering fix
2025-01-22 11:12:23 +01:00
Ashish Jain
963efa64c7 Added changeset 2025-01-22 11:01:37 +01:00
Ashish Jain
e2e5101005 Handle more override edge animate 2025-01-22 10:57:57 +01:00
saurabhg772244
6ea13cded3 Fixed binding issue 2025-01-22 12:27:32 +05:30
Ashish Jain
c063b92cc9 Handle more edge cases, and lint fixes 2025-01-22 02:03:29 +01:00
autofix-ci[bot]
304f133227 [autofix.ci] apply automated fixes 2025-01-22 00:14:56 +00:00
Ashish Jain
54a0dd0af6 Make flowchart edge Ids consistent across getEdges and getData 2025-01-22 01:09:49 +01:00
yari-dewalt
54ee6bd46d Update styles 2025-01-21 11:27:29 -08:00
yari-dewalt
f0e47f29fd Create and register requirementBox shape 2025-01-21 11:27:09 -08:00
Ashish Jain
ab5b7694c6 Merge branch 'develop' into edge-flicker-fix 2025-01-21 17:31:06 +01:00
Ashish Jain
eb76dfb1ca Merge pull request #6205 from mermaid-js/Refactor/fix-styles
fix: styles for Sankey, Gantt, and User Journey diagrams
2025-01-21 17:30:51 +01:00
Saurabh Gore
28d7ec092c Merge branch 'develop' into Refactor/fix-styles 2025-01-21 20:10:43 +05:30
Ashish Jain
84b03f3a08 Merge pull request #6196 from mermaid-js/6195-at-signs-in-labels
#6195 at signs in labels
2025-01-21 15:19:39 +01:00
saurabhg772244
f9ac9867c1 Updated as per Alois suggestion. 2025-01-21 19:21:56 +05:30
saurabhg772244
ee6fb83265 Used 'options' instead of 'var(--mermaid-font-family)' 2025-01-21 18:27:05 +05:30
saurabhg772244
46c16c963b Minor change. 2025-01-21 15:32:53 +05:30
saurabhg772244
32a68d489e Added changeset 2025-01-21 11:35:23 +05:30
saurabhg772244
7bbebff583 Updated styles implementation 2025-01-20 20:30:28 +05:30
saurabhg772244
c432aec2f6 fix: styles for Sankey, Gantt, and User Journey diagrams 2025-01-20 20:05:51 +05:30
Feroz Mujawar
64237fbaa7 updated addSingleLink for multiple outgoing edges to same end node 2025-01-20 19:59:46 +05:30
yari-dewalt
d90609b26c Setup renderer and data collection 2025-01-17 11:02:47 -08:00
yari-dewalt
adec6cd254 Change Db to typescript and add types 2025-01-17 09:27:54 -08:00
Sidharth Vinod
5ce60cacbf Merge pull request #6199 from mermaid-js/update-blog
DOCS: update Blog page
2025-01-17 22:56:05 +05:30
Sidharth Vinod
9ddedb0b49 Revert lock file changes 2025-01-17 22:55:14 +05:30
Steph
e977deaf11 Delete pnpm-lock.yaml 2025-01-17 08:24:24 -08:00
autofix-ci[bot]
85a7771b70 [autofix.ci] apply automated fixes 2025-01-17 16:09:34 +00:00
Sidharth Vinod
3778fef1a1 Merge pull request #6144 from mermaid-js/update-discord-links
Update Discord links
2025-01-17 21:37:43 +05:30
Steph
0bff720e20 add new blog posts 2025-01-17 07:59:28 -08:00
Feroz Mujawar
7ba415dad1 edge flickering fix 2025-01-17 21:23:30 +05:30
Knut Sveidqvist
7f47678862 Spellfix in changeset 2025-01-17 11:50:22 +01:00
Knut Sveidqvist
127bac1147 Adding changeset 2025-01-17 11:48:28 +01:00
Knut Sveidqvist
9a90d795ca #6195 Updated lexer to not allow quotes in link ids 2025-01-17 11:46:44 +01:00
saurabhg772244
f7fe8f2f59 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-flowDb-to-class 2025-01-16 15:17:24 +05:30
Ashish Jain
1d9c2aab8d #6186 Fix for flowchart new syntax with link 2025-01-15 13:45:04 +01:00
saurabhg772244
8fba9c1236 convert flowDb to class and added test cases. 2025-01-15 18:02:04 +05:30
Knut Sveidqvist
04800ff677 Merge pull request #6187 from mermaid-js/flowchart-new-syntax-bugs
#6186 Fixes the flowchart node metadata syntax bugs
2025-01-15 11:45:11 +01:00
saurabhg772244
5d3d1047a4 convert sequenceDb to class. 2025-01-15 15:37:33 +05:30
saurabhg772244
0f08c3bc9c Updated FlowDB instance. 2025-01-14 19:02:50 +05:30
Ashish Jain
7809b5a93f #6186 Fixes the flowchaart node metadata syntax bugs 2025-01-14 14:07:25 +01:00
saurabhg772244
ef9bb53e67 Code refactor 2025-01-14 15:32:47 +05:30
saurabhg772244
3e32332814 Added changeset. 2025-01-14 15:22:14 +05:30
saurabhg772244
e1aab25144 Updated changeset message. 2025-01-14 12:45:56 +05:30
saurabhg772244
c8697301ee Code refactor. 2025-01-14 12:21:07 +05:30
saurabhg772244
fcb1de915b convert stateDb to class, added test case. 2025-01-13 20:30:38 +05:30
autofix-ci[bot]
e345294658 [autofix.ci] apply automated fixes 2025-01-12 14:01:18 +00:00
Balthasar Glättli
9936099e25 Update integrations-community.md
Replaced outdated and lo longer maintained WordPress plugins with actually maintained MerPress Plugin
2025-01-12 14:53:19 +01:00
autofix-ci[bot]
59352ad4d8 [autofix.ci] apply automated fixes 2025-01-11 16:39:40 +00:00
renovate[bot]
ba70f15de5 fix(deps): update all patch dependencies 2025-01-11 16:32:14 +00:00
autofix-ci[bot]
e70b069576 [autofix.ci] apply automated fixes 2025-01-10 14:23:09 +00:00
André Jaenisch
28bab4a323 Update integrations-community.md
Added Forgejo as integration
2025-01-10 15:11:22 +01:00
Saurabh Gore
6cc31b7453 Added changeset 2025-01-10 13:33:04 +05:30
Saurabh Gore
29ca1504dd Added unit test cases for flow DB to have functions used in flow JISON 2025-01-10 13:19:13 +05:30
saurabhg772244
16d2251e43 Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/refactor/convert-flowDb-to-class 2025-01-10 11:15:39 +05:30
Ashish Jain
bc2cc61240 Merge pull request #6136 from mermaid-js/5813-edge-bugfix
Adding animations to flowchart edges also fixing bug with invisible edges
2025-01-07 09:59:52 +01:00
Saurabh Gore
6836e9c7a8 Updated test cases 2025-01-07 12:03:54 +05:30
Saurabh Gore
8dc016e7f9 Update packages/mermaid/src/mermaidAPI.spec.ts
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-01-06 16:43:49 +05:30
Saurabh Gore
3cad7984a3 Update packages/mermaid/src/mermaidAPI.spec.ts
Co-authored-by: Alois Klink <alois@aloisklink.com>
2025-01-06 16:37:51 +05:30
Saurabh Gore
f5bae98098 Set generation to gen-2 in clear 2025-01-03 14:55:20 +05:30
Saurabh Gore
0695893e30 Added test cases 2025-01-03 11:30:21 +05:30
Saurabh Gore
9ef6090c8c convert flowDb to class. 2024-12-31 17:40:52 +05:30
Steph
fa6f3e5fff update Discord links 2024-12-19 13:53:06 -08:00
Knut Sveidqvist
ec0d9c389a Adding changeset 2024-12-18 11:59:39 +01:00
Knut Sveidqvist
323b07a2e4 Typescript fix and updating documentation 2024-12-18 11:56:48 +01:00
Knut Sveidqvist
c153d0455f #5574 Fixed issue linkStyles 2024-12-17 16:28:38 +01:00
Knut Sveidqvist
9b00f1f2fb #5574 Adding support for edge ids and animations 2024-12-17 14:56:18 +01:00
autofix-ci[bot]
a055ff7db3 [autofix.ci] apply automated fixes 2024-12-02 18:14:21 +00:00
Zack Katz
d032723a47 Youtube --> YouTube 2024-12-02 11:56:17 -05:00
Royal Jain
daf83f596d Add Mermaid AI Bot in Readme 2024-11-29 16:46:15 +05:30
Sidharth Vinod
df636c6d0a Merge pull request #6001 from michaelbaudino/patch-1
Fix a configuration example in `gantt.md`
2024-11-28 09:10:56 +05:30
Ashish Jain
64554a6c60 Merge pull request #6092 from mermaid-js/master
Merge back master to develop
2024-11-27 18:24:31 +01:00
Knut Sveidqvist
becadf0a7d Merge pull request #6091 from mermaid-js/changeset-release/master
Version Packages
2024-11-27 18:14:40 +01:00
Sidharth Vinod
54d485f173 Merge branch 'develop' into patch-1 2024-11-27 21:50:42 +05:30
Ashish Jain
b4f5b8ddaf Update CHANGELOG.md 2024-11-27 17:13:25 +01:00
github-actions[bot]
cb5c1ae367 Version Packages 2024-11-27 16:10:54 +00:00
Knut Sveidqvist
b29081d4e8 Merge pull request #6090 from mermaid-js/hotfix/elk-0.1.7
Hotfix/elk 0.1.7
2024-11-27 17:08:48 +01:00
Knut Sveidqvist
654097c438 Added changeset 2024-11-27 17:05:58 +01:00
Knut Sveidqvist
1e672868c4 #6088 Updated offset calculations 2024-11-27 17:05:58 +01:00
Sidharth Vinod
bff32827b5 Merge pull request #6064 from NicolasNewman/5952/architecture-extreme-height
Fix: edge case causing extreme height in Architecture Diagrams
2024-11-27 17:18:41 +05:30
Ashish Jain
65f9b29b86 Merge back master 11.4.1 to develop 2024-11-27 12:08:28 +01:00
Knut Sveidqvist
9868f3a4c3 Merge pull request #6084 from mermaid-js/changeset-release/master
Version Packages
2024-11-27 12:01:43 +01:00
Sidharth Vinod
b4879d13b8 Merge pull request #6036 from docxml/patch-1
Typo kanban.md
2024-11-27 15:08:57 +05:30
Sidharth Vinod
95964b5487 Merge pull request #6055 from agokhale/no-dev-elk-import
Use layout-elk in example.html
2024-11-27 15:07:13 +05:30
Sidharth Vinod
4e17da0a30 fix: Add layout-elk in example.html 2024-11-27 15:05:40 +05:30
github-actions[bot]
d8bf155f0e Version Packages 2024-11-27 09:21:59 +00:00
Sidharth Vinod
0b4f85230a Merge pull request #6083 from mermaid-js/release/11.4.1
Release/11.4.1
2024-11-27 14:49:50 +05:30
Ashish Jain
0dff4ca438 chore: broken link clean up. Enable flowchart elk tests 2024-11-27 09:49:26 +01:00
Ashish Jain
cc29437ede Merge pull request #6081 from mermaid-js/6080-fix
fix: Elk rendering of Diamond shape intersections
2024-11-26 10:52:42 +01:00
Ashish Jain
dfaaf361f3 Merge pull request #6079 from aloisklink/chore/update-to-dompurify-3.2.1
fix: update dompurify to `^3.2.1` and remove `@types/dompurify`
2024-11-26 10:48:23 +01:00
Knut Sveidqvist
37538310d3 Added cypress test 2024-11-25 17:15:59 +01:00
Knut Sveidqvist
c7ae08abc3 #6080: Fix for issue with diamond intersections when using elk-layout 2024-11-25 17:15:35 +01:00
Knut Sveidqvist
69973eaa02 Merge branch 'develop' into 6080-fix 2024-11-25 17:12:29 +01:00
Knut Sveidqvist
d3b2c7ea18 Revert "#6080: Fix for issue with diamond intersections when using elk-layout"
This reverts commit 255279eb22.
2024-11-25 17:10:25 +01:00
Knut Sveidqvist
68f41f685d Added changeset 2024-11-25 16:59:04 +01:00
Knut Sveidqvist
255279eb22 #6080: Fix for issue with diamond intersections when using elk-layout 2024-11-25 16:50:16 +01:00
Alois Klink
fe3cffbb67 chore: update dompurify to ^3.2.1
As [DOMPurify 3.2.0 added TypeScript types][1], this means that we can
remove our dependency on the `@types/dompurify` package.

[DOMPurify 3.2.0 also adds the `HTML_INTEGRATION_POINTS` option][2],
which adds back support for `<foreignObject>`,
[which broke in DOMPurify 3.1.7.][3]

[1]: https://github.com/cure53/DOMPurify/releases/tag/3.2.0
[2]: e4caa67971
[3]: de2c05cd54
2024-11-25 21:00:49 +09:00
NicolasNewman
2a91849a38 chore(#5952): changeset 2024-11-16 10:03:13 -06:00
Nicolas Newman
082de76eef Merge branch 'mermaid-js:develop' into 5952/architecture-extreme-height 2024-11-16 09:55:48 -06:00
NicolasNewman
570ae78b15 cicd(#5952): added test case for diagram that instigated the issue 2024-11-15 10:28:50 -06:00
NicolasNewman
885ac6f947 fix(#5952): handled additional edge cases 2024-11-15 10:27:20 -06:00
Ashish Jain
8328f74751 Merge pull request #6059 from mermaid-js/6058-task-id-as-a-number
fix:Kanban diagrams will not render when adding a number as ticket id or assigned for a task
2024-11-14 16:32:32 +00:00
Knut Sveidqvist
01b5079562 Adding changeset 2024-11-14 15:13:07 +01:00
Knut Sveidqvist
6b23647bec #6058 Casting task-id and assigned fields to string after yaml parsing 2024-11-14 15:07:46 +01:00
agokhale
193fdb225e the ELK imports break the dev playground, drop them 2024-11-13 05:16:01 -05:00
Alois Klink
c8ce416aba Merge pull request #6038 from mermaid-js/fix-for-tilted-cylinder-intersect
Fix for intersection issue
2024-11-08 13:27:57 +00:00
Knut Sveidqvist
1388662132 Added changeset 2024-11-08 13:54:28 +01:00
Knut Sveidqvist
757627427b Fix for intersection issue 2024-11-08 13:47:39 +01:00
autofix-ci[bot]
7cbd80af33 [autofix.ci] apply automated fixes 2024-11-08 11:05:26 +00:00
docxml
16c448b89b Typo kanban.md 2024-11-08 10:59:10 +00:00
Ashish Jain
c218e365bd Merge pull request #6032 from mermaid-js/master
Merge back v4.11.0 to develop
2024-11-07 12:14:09 +00:00
Sidharth Vinod
f507dbbe00 Merge pull request #6010 from mermaid-js/update-whiteboard-tagline
TopBar: update Whiteboard tagline
2024-11-06 11:42:22 +05:30
Sidharth Vinod
9966beb99b Merge pull request #6016 from mermaid-js/update-blog
DOCS: add latest blog posts
2024-11-06 11:42:08 +05:30
Steph
f4713332c0 minor fix 2024-11-05 07:58:56 -08:00
Steph
63ff5b1d98 update utm 2024-11-05 07:57:55 -08:00
NicolasNewman
cb0a4703bd fix(#5952): initial fix for architecture diagrams with extreme heights 2024-11-03 15:53:09 -06:00
Steph
7e71b85668 update blog page 2024-11-01 06:43:26 -07:00
Steph
1dd7bcb0a6 minor update 2024-10-30 09:20:35 -07:00
Steph
bbf6ab1206 update whiteboard tagline 2024-10-30 08:58:52 -07:00
Knut Sveidqvist
56f522ec50 Merge pull request #6008 from mermaid-js/changeset-release/master
Version Packages
2024-10-30 16:42:15 +01:00
github-actions[bot]
d4e5acc530 Version Packages 2024-10-30 15:19:33 +00:00
Knut Sveidqvist
ef9cbb61e5 Merge pull request #6009 from mermaid-js/chore/fix-changeset-for-#5880
chore: update changeset for #5880
2024-10-30 16:17:20 +01:00
Alois Klink
8a0ecc1fe9 chore: update changeset for #5880
This isn't documented, but apparently changesets supports this in 91d1ef2ef7

This is needed to give @yari-dewalt credit for PR #5880
2024-10-31 00:09:10 +09:00
Ashish Jain
c6e1271ef7 Merge pull request #6007 from mermaid-js/release/11.4.0
Release v11.4.0
2024-10-30 15:19:37 +01:00
autofix-ci[bot]
b02294376a [autofix.ci] apply automated fixes 2024-10-30 14:05:05 +00:00
Ashish Jain
97c61d818c added changeset for class diagram 2024-10-30 14:11:41 +01:00
Alois Klink
1c66237fa8 test(unit): update docs unit test snapshot
This snapshot should have been modified in
c1ca3511c (Fix (tmp) for handling of config of htmlLabels ion note. MOvint class box out of flowchart docs, 2024-10-30

Fixes: c1ca3511c4
2024-10-30 21:41:38 +09:00
Knut Sveidqvist
8ef5d324fd Typescript fixes 2024-10-30 13:32:03 +01:00
Knut Sveidqvist
c1ca3511c4 Fix (tmp) for handling of config of htmlLabels ion note. MOvint class box out of flowchart docs 2024-10-30 11:54:31 +01:00
Alois Klink
953d288957 refactor(types): fix kanbanRenderer types
Add the appropriate type checks to ensure that we're only ever calling:

- `insertCluster()` with `ClusterNode`
- `insertNode()` with a `NonClusterNode`

Fixes: 7401cb8f6a
2024-10-30 19:00:35 +09:00
Alois Klink
143806b360 refactor(types): assert insertNode returns non-empty
Fixes: 7401cb8f6a
2024-10-30 19:00:35 +09:00
Alois Klink
a381ab6c41 refactor(types): separate ClusterNodes
Fixes: 7401cb8f6a
2024-10-30 19:00:34 +09:00
Ashish Jain
93e20fdaa3 Merge from develop 2024-10-30 10:38:51 +01:00
Knut Sveidqvist
ece3b254db Merge pull request #6006 from yari-dewalt/fix-note-non-html-text
Fix note non html text
2024-10-30 10:37:35 +01:00
Yari DeWalt
dd42305e8c Merge branch 'develop' into fix-note-non-html-text 2024-10-29 12:21:52 -07:00
yari-dewalt
c34fd152d5 Add handling for ' characters in non-html text so they don't get sanitized into html code values 2024-10-29 11:57:22 -07:00
yari-dewalt
8f0e0b9c39 Change useHtmlLabels to use general config's htmlLabels attribute not flowchart's 2024-10-29 11:55:34 -07:00
yari-dewalt
fe8932e906 Set node.centerLabel before using labelHelper() 2024-10-29 11:54:25 -07:00
yari-dewalt
5a2a8f9bd4 Fix typos 2024-10-29 10:33:50 -07:00
Yari DeWalt
9854748fc3 Merge branch 'develop' into update-er-diagram 2024-10-29 10:23:14 -07:00
Knut Sveidqvist
73bbde8476 Update of the background-fix 2024-10-29 16:21:56 +01:00
Knut Sveidqvist
01a41ef530 Merge branch 'release/11.4.0' of github.com:mermaid-js/mermaid into release/11.4.0 2024-10-29 14:52:25 +01:00
Knut Sveidqvist
124d2f72dd Fix for icon borders 2024-10-29 14:51:55 +01:00
Alois Klink
34e8946c58 refactor(types): fix kanbanItem circular types
Exclude the `node.shape` type from `kanbanItem()`, as otherwise it
causes a circular dependency in the types.
2024-10-29 22:18:38 +09:00
Ashish Jain
0197c08916 revert adding kanban section to shape 2024-10-29 14:04:57 +01:00
Alois Klink
ef30283fe9 refactor: fix more type errors in kanbanItem
Fixes: 7401cb8f6a
2024-10-29 21:44:34 +09:00
Ashish Jain
dffaf9fa8f fix for kanban section shape 2024-10-29 13:41:20 +01:00
Alois Klink
9168d5d1f4 refactor(types): fix some type errors in kanbanItem
Fixes: 7401cb8f6a
2024-10-29 21:14:51 +09:00
Alois Klink
f33ebfaf7a refactor: fix broken generic on insertLabel()
Fixes: 7401cb8f6a
2024-10-29 21:14:48 +09:00
Alois Klink
054f929150 refactor: remove unused param from labelHelper()
Fixes: 7401cb8f6a
2024-10-29 21:14:40 +09:00
autofix-ci[bot]
8cb1c68166 [autofix.ci] apply automated fixes 2024-10-29 13:09:54 +01:00
Michael Baudino
d752240efc Fix a configuration example in gantt.md
According to the [config schema docs](https://mermaid.js.org/config/schema-docs/config-defs-gantt-diagram-config.html#tickinterval-constraints), Gantt's `tickInterval` configuration must match the following regular expression, which does **not** allow any space:

```regexp
/^([1-9][0-9]*)(millisecond|second|minute|hour|day|week|month)$/
```
2024-10-29 13:09:54 +01:00
Knut Sveidqvist
8d0902de4c Merge pull request #6002 from aloisklink/fix/make-parse-error-on-invalid-shape
fix: make `mermaid.parse` throw an error on invalid shapes
2024-10-29 10:46:02 +01:00
Knut Sveidqvist
f6c32b6da4 Merge branch 'develop' into fix/make-parse-error-on-invalid-shape 2024-10-29 10:45:50 +01:00
Knut Sveidqvist
bdf145ffe3 Merge pull request #5880 from yari-dewalt/update-class-diagram
Update class diagram to v3 using new renderer
2024-10-29 10:44:07 +01:00
Knut Sveidqvist
75ca802b62 Merge branch 'develop' into update-class-diagram 2024-10-29 10:40:39 +01:00
Ashish Jain
3f85b6179d Merge pull request #5999 from mermaid-js/knsv/5342-kanban
Knsv/5342 kanban
2024-10-29 10:38:18 +01:00
yari-dewalt
5ae5a0cea3 Merge branch 'develop' into update-er-diagram and fix conflicts 2024-10-28 10:53:45 -07:00
yari-dewalt
b315d70af5 Merge branch 'develop' into update-class-diagram and fix conflicts 2024-10-28 10:32:19 -07:00
autofix-ci[bot]
848be3d129 [autofix.ci] apply automated fixes 2024-10-28 14:33:47 +00:00
Alois Klink
5fabd414fb fix: error mermaid.parse on invalid shapes
Currently, invalid shapes cause an error when rendering, but not when
parsing. This confuses the Mermaid Live Editor, e.g. by not showing the
error message.

Instead, I've added an `isValidShape()` that validates if the shape is
valid at parse time. This only checks shapes using the new extended
shapes syntax. Currenlty, using `A(-this is an ellipse node-)` is broken
(see #5976) and also causes an invalid shape error at render time, but
I've ignored it in this PR, so it will continue pass at parse-time
(we have unit tests checking ellipse parsing).

See: https://github.com/mermaid-js/mermaid/issues/5976
2024-10-28 23:17:13 +09:00
Alois Klink
17e2f9e0d4 refactor: fix addVertex type parameter
I went through
`packages/mermaid/src/diagrams/flowchart/parser/flow.jison` and found
every possible value this `type` parameter could be.
2024-10-28 23:17:13 +09:00
Alois Klink
7fa8b35bdc refactor: convert if-statements to switch..case 2024-10-28 23:17:13 +09:00
Knut Sveidqvist
e6ea4eae50 Fix for missing function 2024-10-28 14:29:06 +01:00
Knut Sveidqvist
7401cb8f6a Merge branch 'develop' into knsv/5342-kanban 2024-10-28 14:22:10 +01:00
Sidharth Vinod
e765007b21 Merge pull request #5974 from aloisklink/refactor/improving-rendering-shape-types
refactor: TypeScript improvements to `packages/mermaid/src/rendering-util/rendering-elements`
2024-10-28 18:22:23 +05:30
Sidharth Vinod
b5cd101d86 Merge branch 'develop' into refactor/improving-rendering-shape-types 2024-10-28 18:11:41 +05:30
autofix-ci[bot]
da12ace593 [autofix.ci] apply automated fixes 2024-10-28 12:08:48 +00:00
Knut Sveidqvist
2c676b6222 Moving kanbanItem out of the shapes doc 2024-10-28 13:03:18 +01:00
Knut Sveidqvist
0af08276d2 #5232 Enabling handdrawn mode 2024-10-28 12:53:03 +01:00
Knut Sveidqvist
d790e353b0 #5432 Theme based text color for labels 2024-10-28 11:51:44 +01:00
Knut Sveidqvist
e07e9b9daf Merge branch 'knsv/5342-kanban' of github.com:mermaid-js/mermaid into knsv/5342-kanban 2024-10-28 11:47:17 +01:00
Knut Sveidqvist
948ec4d1ce #5342 Handing of wide section texts 2024-10-28 11:43:56 +01:00
autofix-ci[bot]
e62d268c89 [autofix.ci] apply automated fixes 2024-10-28 09:19:37 +00:00
Knut Sveidqvist
742ad7c130 Adding changeset and kanban in the docs sidenav 2024-10-28 10:03:42 +01:00
Knut Sveidqvist
56cc3728c5 End to end tests and docs 2024-10-25 15:40:58 +02:00
Knut Sveidqvist
fb86e5c689 Merge branch 'develop' into knsv/5342-kanban 2024-10-25 14:56:46 +02:00
yari-dewalt
01e5346004 Update handling of classes and add support for default class 2024-10-24 10:18:17 -07:00
yari-dewalt
1b34077f55 Adjust tests 2024-10-23 12:26:19 -07:00
Yari DeWalt
87fa698c79 Merge branch 'develop' into update-er-diagram 2024-10-23 12:07:27 -07:00
yari-dewalt
b49afeefc2 Cleanup 2024-10-23 12:06:59 -07:00
yari-dewalt
8ace44b428 Add fix for edge markers showing under node if handDrawn 2024-10-23 12:02:49 -07:00
yari-dewalt
39a6c308fb Fix conflict with style statements 2024-10-23 12:01:08 -07:00
yari-dewalt
2771b14f65 Update tests 2024-10-23 12:00:21 -07:00
autofix-ci[bot]
9ff09f28e7 [autofix.ci] apply automated fixes 2024-10-23 14:25:38 +00:00
Jake Beamish
eddd8313c9 Fix code block typo
Previously, the h4 line "#### Using Dagre Layout with Classic Look:" was included at the bottom of the previous Example configuration code block. Now it renders as a h4
2024-10-23 15:03:36 +01:00
Alois Klink
f8746bee04 refactor: move MaybePromise type to src/types.ts
Suggested-by: https://github.com/mermaid-js/mermaid/pull/5974#discussion_r1810562136
Co-authored-by: Sidharth Vinod <sidharthv96@gmail.com>
2024-10-22 21:49:23 +09:00
Alois Klink
bb97fdbd1e refactor: use parseFontSize()
Handle `NaN` values by using `parseFontSize()`.

Suggested-by: https://github.com/mermaid-js/mermaid/pull/5974#discussion_r1810570967
2024-10-22 21:49:02 +09:00
Sidharth Vinod
e3ec6ed993 Merge pull request #5987 from mermaid-js/update-promos
Remove Product Hunt promos & Update Promo bar
2024-10-22 12:03:05 +05:30
Steph
6df1fa1a03 update taglines 2024-10-21 23:26:17 -07:00
yari-dewalt
fd6b875f87 Fix subgraph / cluster node width based off of label 2024-10-21 16:09:55 -07:00
yari-dewalt
be3da0b39d Update testing file 2024-10-21 15:37:41 -07:00
yari-dewalt
64bc7f4bd9 Add fix for flipped edge markers 2024-10-21 15:37:24 -07:00
Yari DeWalt
75e796f183 Merge branch 'develop' into update-class-diagram 2024-10-21 15:36:29 -07:00
Alois Klink
6cc0132e0a refactor(elk): add LabelData type for layout-elk
I don't know what exactly the type does or is for, but I've tried to
type it to what it seems to be.
2024-10-21 22:23:36 +09:00
Alois Klink
4bc70b7325 refactor: use more standard types
See: https://github.com/mermaid-js/mermaid/pull/5974#discussion_r1806473749
See: https://github.com/mermaid-js/mermaid/pull/5974#discussion_r1808511738

Co-authored-by: saurabhg772244 <saurabh@mermaidchart.com>
2024-10-21 22:23:36 +09:00
Bryan
c828867852 add documentation 2024-10-19 17:50:00 +01:00
yari-dewalt
bfdd0f244d Fix tests to work with new cssClasses attribute 2024-10-18 16:36:06 -07:00
Bryan
5fca47c5ec Revert "run prettier"
This reverts commit 6d33d93b15.
2024-10-18 21:30:10 +01:00
Bryan
4cd3f0a8bb try implementing assert as if->throw 2024-10-18 21:21:15 +01:00
Bryan
73653c348d remove import for assert 2024-10-18 21:12:55 +01:00
Bryan
0bc07f356d add import for assert 2024-10-18 20:54:10 +01:00
Bryan
6d33d93b15 run prettier 2024-10-18 20:28:37 +01:00
autofix-ci[bot]
d54eed9d62 [autofix.ci] apply automated fixes 2024-10-18 19:22:20 +00:00
Bryan
0fdfd91069 lint the documentation 2024-10-18 20:17:30 +01:00
Bryan
93577619b2 add documentation 2024-10-18 20:09:29 +01:00
Bryan
b602f67abe Add bit count syntax to packet diagram 2024-10-18 20:05:42 +01:00
yari-dewalt
0e819ae050 Change cssClasses to use concatenated string instead of array to pick up css styles 2024-10-18 10:33:56 -07:00
yari-dewalt
10f11e016f Merge branch 'update-class-diagram' of github.com:yari-dewalt/mermaid into update-class-diagram 2024-10-18 10:12:48 -07:00
yari-dewalt
b7d66bb975 Add elk and handDrawn specific test files 2024-10-18 10:12:09 -07:00
yari-dewalt
74695d2e88 Fix undesired wrapping on notes 2024-10-18 10:11:36 -07:00
Steph
38eed7c988 product hunt promo material updates 2024-10-18 09:54:46 -07:00
Alois Klink
d16e46a386 Merge pull request #5972 from gabeidx/zed-mermaid
docs(ecosystem): Add Zed extension zed-mermaid
2024-10-18 08:45:30 +00:00
Alois Klink
97820a50c2 Merge pull request #5918 from vorburger/patch-2
docs: Fix inconsistency in Block Diagram doc example
2024-10-18 08:42:34 +00:00
Alois Klink
df948bcf2c Merge pull request #5968 from eitsupi/fix-ssg
docs(integrations): fix listing order
2024-10-18 08:39:31 +00:00
Alois Klink
cfd097b029 Merge pull request #5967 from yihui/patch-1
docs: bullet lists should not be code blocks
2024-10-18 08:37:12 +00:00
Alois Klink
ffc1fef599 Merge pull request #5957 from TomasHubelbauer/patch-1
Remove extraneous period
2024-10-18 08:36:31 +00:00
Alois Klink
1e8e4e4b73 Merge branch 'develop' into patch-2 2024-10-18 08:34:07 +00:00
yari-dewalt
b67cdb171d Fix for edge markers displaying above nodes when using elk 2024-10-17 17:59:41 -07:00
yari-dewalt
c789172b89 Update tests 2024-10-17 17:58:46 -07:00
yari-dewalt
1d68c4f075 Update to test elk layout 2024-10-17 17:58:19 -07:00
autofix-ci[bot]
606ecf8990 [autofix.ci] apply automated fixes 2024-10-17 17:42:10 +00:00
Alois Klink
16a5fc05d6 refactor: remove some any types from render()
This let's us confirm that the types we're passing to `insertNode()` are
valid.
2024-10-18 01:51:53 +09:00
Alois Klink
62fd359c0e refactor: convert shapes/util.js to TypeScript
Convert the
`packages/mermaid/src/rendering-util/rendering-elements/shapes/util.js`
file to TypeScript at:
`packages/mermaid/src/rendering-util/rendering-elements/shapes/util.ts`.
2024-10-18 01:51:53 +09:00
Alois Klink
b0f4ace3a1 refactor: convert rendering-elements/nodes to TS
Convert the
`packages/mermaid/src/rendering-util/rendering-elements/nodes.js`
file to TypeScript at
`packages/mermaid/src/rendering-util/rendering-elements/nodes.ts`
2024-10-18 01:51:53 +09:00
autofix-ci[bot]
6f506c30eb [autofix.ci] apply automated fixes 2024-10-17 16:04:56 +00:00
yari-dewalt
cf2c7f7f8c Update tests 2024-10-17 08:58:49 -07:00
yari-dewalt
6041729ae2 Add suport for start and end labels (cardinality) in elk renderer 2024-10-17 08:58:06 -07:00
yari-dewalt
b7ef8b2b5a Refactor to make code more clear 2024-10-17 08:57:03 -07:00
yari-dewalt
bfea287b44 Register and update classBox shape 2024-10-17 08:55:42 -07:00
Alois Klink
9afb181d06 refactor: correct shapes types
All of the shapes in
`packages/mermaid/src/rendering-util/rendering-elements/shapes/` use
`D3.Selection`s as input parameters and as return parameters.

Although, for some reason, passing them to roughjs seems to work?
2024-10-17 22:29:38 +09:00
Alois Klink
cfe7cce41d refactor: improve types of shapes
Instead of being a `Record<string, ShapeHandler>`, the type now knows
every key in the variable.
2024-10-17 18:59:43 +09:00
autofix-ci[bot]
33029c8bd2 [autofix.ci] apply automated fixes 2024-10-17 08:31:48 +00:00
Gabriel Silva
e54d10c706 docs(ecosystem): Add Zed extension zed-mermaid to community integrations 2024-10-17 10:21:15 +02:00
yari-dewalt
df22fb5e00 Merge branch 'update-er-diagram' of github.com:yari-dewalt/mermaid into update-er-diagram 2024-10-16 09:48:49 -07:00
yari-dewalt
5d2b0f74af Add fix for er markers when using elk layout 2024-10-16 09:48:15 -07:00
Yari DeWalt
86c7532f46 Merge branch 'develop' into update-class-diagram 2024-10-16 09:43:58 -07:00
autofix-ci[bot]
723b8f1d32 [autofix.ci] apply automated fixes 2024-10-16 15:20:09 +00:00
yari-dewalt
5be5aa3dfa Register erBox shape 2024-10-16 08:14:13 -07:00
Yari DeWalt
69e12fd67d Merge branch 'develop' into update-er-diagram 2024-10-16 08:09:51 -07:00
eitsupi
8aa87c7091 docs(integrations): fix listing order 2024-10-16 21:36:26 +09:00
autofix-ci[bot]
e1024838e8 [autofix.ci] apply automated fixes 2024-10-16 03:52:48 +00:00
Yihui Xie
4cce43f0a1 Bullet lists should not be code blocks 2024-10-15 22:45:38 -05:00
yari-dewalt
49e23c74bc Update parser to include changes 2024-10-15 12:19:35 -07:00
yari-dewalt
8b169f3796 Fix issue with text content using < and > 2024-10-15 11:46:31 -07:00
yari-dewalt
b5da91b29a Update 2024-10-15 11:45:59 -07:00
yari-dewalt
1d4ea56740 Support direction data 2024-10-15 11:44:58 -07:00
yari-dewalt
0d664b1fd2 Add tests 2024-10-15 11:44:02 -07:00
yari-dewalt
29c3293265 Update documentation 2024-10-15 11:42:47 -07:00
autofix-ci[bot]
c69ab34eac [autofix.ci] apply automated fixes 2024-10-11 20:27:05 +00:00
Tomáš Hübelbauer
7353be3b16 Remove extraneous period
Other cells in the table do not end with one.
2024-10-11 22:21:23 +02:00
Knut Sveidqvist
02be63ed72 Refactoring and cleanup including updated unit tests 2024-10-11 08:48:04 -07:00
Sidharth Vinod
742531a2c2 Merge pull request #5951 from gbremond/docs/5949_update-icon-name-for-database
docs(architecture): update icon name for database in exemple
2024-10-11 06:12:42 +00:00
Knut Sveidqvist
991d403d7f Typescript fixes 2024-10-10 09:47:52 -07:00
Knut Sveidqvist
290c678dc7 Adding ticket handling 2024-10-10 08:23:58 -07:00
g.bremont-ext
2c31a599af docs(architecture): use right icon for database in exemple 2024-10-10 17:00:13 +02:00
autofix-ci[bot]
2655be0bad [autofix.ci] apply automated fixes 2024-10-10 14:21:46 +00:00
g.bremont-ext
4f97c8c70e docs(architecture): update icon name for database in exemple 2024-10-10 16:15:23 +02:00
Sidharth Vinod
f85977246c Merge pull request #5945 from mermaid-js/saurabh/doc-update
Updated doc for image and icon shapes
2024-10-10 16:46:02 +05:30
saurabhg772244
a4fd42214b Use relative URL in linking docs 2024-10-10 15:17:26 +05:30
saurabhg772244
ca885027d4 Moved position for icon config and added major version in icon docs 2024-10-10 14:15:16 +05:30
saurabhg772244
9f6f1e96e5 Added new doc for registering icon pack in mermaid 2024-10-10 13:11:54 +05:30
saurabhg772244
351ce30d8a Merge branch 'develop' of https://github.com/mermaid-js/mermaid into saurabh/doc-update 2024-10-10 12:26:14 +05:30
Sidharth Vinod
2933eb5c28 fix: Build options 2024-10-09 16:44:51 +05:30
saurabhg772244
09ecf76034 Updated doc for image and icon shapes 2024-10-09 15:34:12 +05:30
Sidharth Vinod
2b86750cb3 Merge pull request #5924 from mermaid-js/sidv/autoGenerateShapeDocs
Auto generate shape docs
2024-10-09 14:11:56 +05:30
Sidharth Vinod
b45224755e Merge branch 'develop' into sidv/autoGenerateShapeDocs 2024-10-09 13:41:43 +05:30
Sidharth Vinod
14524e1b0e docs: Optimise document generation
Co-authored-by: Alois Klink <alois@aloisklink.com>
2024-10-09 13:39:06 +05:30
Sidharth Vinod
efa47e3176 fix: Docs vitepress build 2024-10-09 13:18:01 +05:30
Sidharth Vinod
1bc45405e0 chore: Generate shape doc before verification 2024-10-09 13:18:01 +05:30
Sidharth Vinod
3720e1a894 docs: Auto generate shape docs
Not keen on how it's currently run, open to suggestions on better ways.
2024-10-09 13:18:00 +05:30
Sidharth Vinod
76138cf3b9 chore: Decouple build logic 2024-10-09 13:17:59 +05:30
Alois Klink
2506c29f6b Merge pull request #5937 from mermaid-js/saurabh/icon-shape-style-fix
Fix icon shape color for colored icons.
2024-10-09 07:47:34 +00:00
Sidharth Vinod
463ba6ed6d Merge pull request #5923 from mermaid-js/sidv/refactorShapes
Refactor shapes definition
2024-10-09 13:17:06 +05:30
saurabhg772244
17b783135f Added pnpm changeset 2024-10-09 12:55:37 +05:30
saurabhg772244
8df2729bd4 Merge branch 'saurabh/icon-shape-style-fix' of https://github.com/mermaid-js/mermaid into saurabh/icon-shape-style-fix 2024-10-09 12:16:05 +05:30
saurabhg772244
a001619464 Move MIT license just before icon definition 2024-10-09 12:15:23 +05:30
Saurabh Gore
3c5a19d297 Merge branch 'develop' into saurabh/icon-shape-style-fix 2024-10-09 11:12:56 +05:30
saurabhg772244
a98290a6e2 remove doc for icon shape 2024-10-09 11:08:27 +05:30
saurabhg772244
9bac464442 Use tropical-fish icon with MIT license in e2e tests 2024-10-09 10:41:37 +05:30
yari-dewalt
df110e5e11 Add default class to nodes and fix styles 2024-10-08 11:47:08 -07:00
yari-dewalt
6247bd5f89 Add test html file 2024-10-08 08:26:43 -07:00
yari-dewalt
cba4752433 Fix diagram title not being centered 2024-10-08 08:26:12 -07:00
yari-dewalt
d0dd4e6e5e Fix cyclical / recursive edges to not show duplicated arrow start markers 2024-10-08 08:25:34 -07:00
yari-dewalt
d2892ea249 Add erDiagram specific arrow markers 2024-10-08 08:24:41 -07:00
yari-dewalt
983c28686f Register erBox shape in nodes 2024-10-08 08:23:51 -07:00
yari-dewalt
f2f1ad4605 Add erBox shape 2024-10-08 08:22:34 -07:00
yari-dewalt
10562e72f4 Initial update to new renderer 2024-10-08 08:12:42 -07:00
autofix-ci[bot]
11fb806992 [autofix.ci] apply automated fixes 2024-10-08 15:03:03 +00:00
Yari DeWalt
d424a4473a Merge branch 'develop' into update-class-diagram 2024-10-08 07:58:15 -07:00
saurabhg772244
4062813d44 Added docs for icon-shape 2024-10-08 17:45:53 +05:30
Sidharth Vinod
29b9d3069b Merge branch 'develop' into sidv/refactorShapes 2024-10-08 16:15:34 +05:30
Sidharth Vinod
c38d9a6620 Merge pull request #5808 from mermaid-js/renovate/patch-all-patch
chore(deps): update all patch dependencies (patch)
2024-10-08 15:11:26 +05:30
Sidharth Vinod
2f65429aa4 chore: Rollback dompurify update range 2024-10-08 15:01:11 +05:30
Sidharth Vinod
c24028f2a4 chore: Separate dompurify updates 2024-10-08 15:00:57 +05:30
autofix-ci[bot]
a20c292653 [autofix.ci] apply automated fixes 2024-10-08 09:17:15 +00:00
renovate[bot]
1c6304b3fb chore(deps): update all patch dependencies 2024-10-08 09:11:33 +00:00
Sidharth Vinod
3ac93af80c Merge pull request #5936 from mermaid-js/renovate/major-eslint
chore(deps): update dependency eslint-plugin-unicorn to v56
2024-10-08 13:58:24 +05:30
renovate[bot]
ce586e1b31 chore(deps): update dependency eslint-plugin-unicorn to v56 2024-10-08 08:18:32 +00:00
Sidharth Vinod
926f97124b Merge pull request #5939 from mermaid-js/renovate/npm-express-vulnerability
chore(deps): update dependency express to v4.20.0 [security]
2024-10-08 13:39:14 +05:30
Sidharth Vinod
0f2301f2d6 Merge pull request #5938 from mermaid-js/renovate/npm-vite-vulnerability
chore(deps): update dependency vite to v5.4.6 [security]
2024-10-08 13:38:29 +05:30
Sidharth Vinod
58e8f65135 Merge pull request #5935 from mermaid-js/renovate/eslint
chore(deps): update eslint to v9.12.0 (minor)
2024-10-08 13:37:54 +05:30
Sidharth Vinod
1b51fbfcca Revert "chore: Split newshape test"
This reverts commit 1b12ac133e.
2024-10-08 13:36:16 +05:30
renovate[bot]
1296840696 chore(deps): update eslint to v9.12.0 2024-10-08 07:57:45 +00:00
Sidharth Vinod
f99e2c9366 fix: Add internalAliases
Co-authored-by: Alois Klink <alois@aloisklink.com>
2024-10-08 13:25:00 +05:30
renovate[bot]
c71b56ebe3 chore(deps): update dependency express to v4.20.0 [security] 2024-10-08 07:52:44 +00:00
renovate[bot]
9904afce64 chore(deps): update dependency vite to v5.4.6 [security] 2024-10-08 07:52:17 +00:00
Sidharth Vinod
a827fb1202 fix: Argos index numbering 2024-10-08 13:20:55 +05:30
Sidharth Vinod
51be99c9de fix: Remove duplicates, add documentation, rename legacyAlias
Co-authored-by: Alois Klink <alois@aloisklink.com>
2024-10-08 13:01:31 +05:30
Sidharth Vinod
b83b778f2a Merge pull request #5933 from remcohaszing/fix-types-dependencies
Fix TypeScript dependencies
2024-10-08 12:55:49 +05:30
Sidharth Vinod
86a91597f9 Upgrade @argos-ci 2024-10-07 19:12:23 +05:30
Sidharth Vinod
1b12ac133e chore: Split newshape test 2024-10-07 18:30:05 +05:30
Sidharth Vinod
e55880a9c4 Merge pull request #5925 from mermaid-js/sidv/parallelCypress
chore: Split cypress tests locally
2024-10-07 17:20:55 +05:30
Sidharth Vinod
9cc309b69c Apply suggestions from code review
Co-authored-by: Alois Klink <alois@aloisklink.com>
2024-10-07 17:20:38 +05:30
saurabhg772244
d3308232e8 updated test case for icon shape 2024-10-07 16:11:31 +05:30
saurabhg772244
0b8f27e1d2 Updated icon shape to use css color style instead of stroke 2024-10-07 15:52:12 +05:30
Knut Sveidqvist
93f2c241b8 5432 WIP, rendering items 2024-10-06 19:22:07 +02:00
Knut Sveidqvist
fb44e769f2 5432 WIP, rendering sections 2024-10-06 18:34:24 +02:00
Knut Sveidqvist
fabdfd9ae8 5432 WIP, parsing works 2024-10-06 16:55:57 +02:00
Remco Haszing
72d60d2633 Fix TypeScript dependencies
The Mermaid type definitions depend on `@types/d3` and
`@types/dompurify`. Without these dependencies, the Mermaid types cause
a type error for users.
2024-10-04 17:19:04 +02:00
Knut Sveidqvist
2d7686eb65 #5342 Initial commit 2024-10-04 16:03:55 +02:00
Sidharth Vinod
d9a26ff193 Merge branch 'develop' into sidv/refactorShapes 2024-10-04 14:44:31 +05:30
Sidharth Vinod
2401eea725 Merge branch 'develop' into sidv/parallelCypress 2024-10-04 14:43:49 +05:30
Sidharth Vinod
ddf18dd233 chore: Disable architecture diagram test 2024-10-04 14:25:45 +05:30
Sidharth Vinod
4b98dabc3f chore: Update test name 2024-10-04 02:56:09 +05:30
Sidharth Vinod
5a3e0ccc3d chore: rebuild 2024-10-04 02:33:45 +05:30
Sidharth Vinod
38a3ad3370 chore: Add timing update action 2024-10-04 02:29:55 +05:30
Sidharth Vinod
b777c12094 chore: Add timings file 2024-10-04 02:29:43 +05:30
Sidharth Vinod
8fc36d2684 chore: Split cypress tests locally 2024-10-04 01:54:36 +05:30
Sidharth Vinod
e2474049d8 Merge branch 'develop' into sidv/refactorShapes
* develop:
  chore: move handDrawnSeed to mermaidUrl function
2024-10-04 01:31:54 +05:30
Sidharth Vinod
6e0fe03552 chore: move handDrawnSeed to mermaidUrl function 2024-10-04 01:31:20 +05:30
Sidharth Vinod
cda48a7143 Merge branch 'develop' into sidv/refactorShapes
* develop:
  fix: Hard code handDrawnSeed
2024-10-04 00:46:01 +05:30
Sidharth Vinod
e5a28de26e fix: Hard code handDrawnSeed 2024-10-04 00:44:08 +05:30
Sidharth Vinod
0ae4f97036 test: Update nodes test 2024-10-04 00:05:38 +05:30
Sidharth Vinod
218bfe1603 chore: Update import path 2024-10-03 22:13:00 +05:30
Sidharth Vinod
339c670839 docs: Update new shape registration doc 2024-10-03 22:12:41 +05:30
Sidharth Vinod
c5a19f6e85 chore: Organize shape handling 2024-10-03 22:08:30 +05:30
autofix-ci[bot]
719685b930 [autofix.ci] apply automated fixes 2024-10-03 08:54:12 +00:00
Michael Vorburger
0cbc000bfa docs: Fix inconsistency in Block Diagram doc example 2024-10-03 10:47:31 +02:00
yari-dewalt
91e3da1293 Update tests to take into account 'default' class 2024-09-24 10:47:26 -07:00
yari-dewalt
fa46267c14 Update documentation 2024-09-24 10:22:46 -07:00
yari-dewalt
10679297f9 Fix conditional logic 2024-09-24 09:35:34 -07:00
yari-dewalt
3e697e2ea4 Update and fix logic for lollipop interfaces 2024-09-24 09:28:17 -07:00
yari-dewalt
f031abcec2 Support lollipop interface feature 2024-09-23 12:19:22 -07:00
yari-dewalt
dd62322ae5 Add default class support 2024-09-23 10:09:05 -07:00
yari-dewalt
48e5dee963 Fix edge markers being flipped 2024-09-23 09:51:36 -07:00
yari-dewalt
bd0a00d373 Update config yaml so ClassDiagramConfig can be properly updated 2024-09-20 09:56:17 -07:00
yari-dewalt
3b8bd6b979 Include classRenderer.js to fix lint error 2024-09-20 09:13:21 -07:00
yari-dewalt
41f22864b4 Add adjustments for text and useHtmlLabels 2024-09-19 12:33:34 -07:00
yari-dewalt
6a99a1a40a Update HTML file and add rendering tests 2024-09-19 12:30:38 -07:00
yari-dewalt
1fcebab9ed Change cssDiagram parameter to 'classDiagram' 2024-09-18 13:22:21 -07:00
yari-dewalt
bed301a485 Update tests 2024-09-18 13:21:27 -07:00
yari-dewalt
31546b08ff Fix note text 2024-09-18 13:20:47 -07:00
yari-dewalt
25337dc453 Update text logic and change workaround for markdown 2024-09-18 12:54:32 -07:00
yari-dewalt
745495c2d5 Refactor and cleanup logic for classBox shape 2024-09-18 09:12:15 -07:00
yari-dewalt
94d2a0ee89 Cleanup 2024-09-18 09:11:25 -07:00
yari-dewalt
b105c7b35e Add node look and fix text attribute on class 2024-09-18 09:10:35 -07:00
yari-dewalt
149f991c1d Fix typo 2024-09-18 08:53:54 -07:00
yari-dewalt
a43ee60942 Add fixes to utils 2024-09-18 08:53:54 -07:00
yari-dewalt
5f11cd417f Add classBox shape 2024-09-18 08:53:54 -07:00
yari-dewalt
3782b69744 Add support for classDef statement 2024-09-18 08:53:54 -07:00
yari-dewalt
ca93280b17 Change types 2024-09-18 08:53:54 -07:00
yari-dewalt
2ec9f0af2e Add support for new renderer 2024-09-18 08:53:54 -07:00
yari-dewalt
3eb338df04 Add default option for hideEmptyBox in config 2024-09-18 08:53:54 -07:00
yari-dewalt
b7790ba6b5 Add diagrams for testing 2024-09-18 08:53:54 -07:00
yari-dewalt
b67c931f18 Update snapshot to include new data 2024-09-18 08:53:54 -07:00
yari-dewalt
97186504b5 Add classifier test diagram 2024-09-18 08:53:54 -07:00
yari-dewalt
bd4ca9af1b Add support for classifiers in text attribute 2024-09-18 08:53:54 -07:00
yari-dewalt
9ac20a5cb8 Add styling compatibility to shape 2024-09-18 08:53:54 -07:00
yari-dewalt
20a58d6dbb Add special handling to avoid markdown to HTML issues 2024-09-18 08:53:54 -07:00
yari-dewalt
191e4217fc Adjust classNode text when label is set 2024-09-18 08:53:54 -07:00
yari-dewalt
8745daa701 Add handling for escape type 2024-09-18 08:53:54 -07:00
yari-dewalt
27f7b615cc Add more tests / samples 2024-09-18 08:53:54 -07:00
yari-dewalt
e3c426de86 Initial work on updating to new renderer 2024-09-18 08:53:54 -07:00
Sidharth Vinod
70038e90ce Merge branch 'develop' into sidv/tinyMermaid
* develop: (52 commits)
  docs: Add quadrant point styling
  feat: Change precedence of styling
  chore(deps): update all minor dependencies
  chore(deps): update all patch dependencies
  fix: eslint ignore, type definition
  chore(deps): update all patch dependencies
  fix: Remove `ImperativeState` type restriction.
  📝🐛 fix schema link
  update latest news section
  Changes to rendering/gitGraph.spec.js - Added additional rendering test functionality for recognizing 'switch' as an alias to 'checkout'.
  1. Changes to gitGraph.jison - Updated the regex to allow either 'checkout' or 'switch' 2. Changes to gitGraphParser.spec.js - Additional test coverage added for the changes made to the parser. 3. Changes to gitGraphParserV2.spec.js - Additional test coverafe added for the changes made to the parser. 4. Changes to gitgraph.md - Updated documentation to let users know that checkout/switch can be used interchangeably.
  revert from and to type to object
  add eslint rule consistent-type-definations
  Update createText.ts
  chore(deps): update all patch dependencies
  revert lock file
  simplify message type from and to
  move types to separate file
  use interfaces instead of types
  feat: create utils func + test cases
  ...
2024-04-16 12:34:42 +05:30
Sidharth Vinod
49f2de9547 Merge branch 'develop' into sidv/tinyMermaid
* develop: (101 commits)
  Add extra test
  Add visual test
  Wait for image to be rendered
  Update docs
  Linting
  chore:  temp fix for eslint OOM
  chore: Update error snapshots
  Fix ESLint
  chore: Prettier
  chore: YOLO `pnpm --recursive update`
  chore: Remove commitlint
  Fix flowchart-elk render test
  chore: Add example page link in index
  Fix flowchart-elk render test
  chore: Add example page link in index
  fix: Remove space which caused extra newline on diagrams
  fix: Remove repeated config calls
  fix: ELK diagram remove re-parsing
  chore: Minor fixes #4856
  chore: Increase ESLint memory limit
  ...
2024-03-23 18:47:27 +05:30
sidharthv96
80eaafa001 Update docs 2024-03-08 14:24:44 +00:00
Sidharth Vinod
cedc1d4e28 Merge branch 'develop' into sidv/tinyMermaid
* develop: (31 commits)
  make LLM integrations a new headline
  build docs
  ci(e2e): avoid commenting on PRs in CI
  chore: Remove unused imports in block
  Fix spelling
  Update docs
  Lychee ignore chrome webstore
  Update link
  chore(deps): update all patch dependencies
  build(docs): vendor CSS dependencies
  chore(deps): update all minor dependencies
  fix linting issues
  Ran lint:fix
  Fix chrome webstore url causing 404
  Add LLM integration section in productivity tools and add HueHive
  build(deps): update `langium` to `v3` and apply the required changes
  Remove dummy change from e2e.yml
  Remove dummy change
  Remove log
  Format message
  ...
2024-03-08 19:43:56 +05:30
Sidharth Vinod
882e4971eb Remove katex from mermaid.tiny 2024-03-01 12:54:42 +05:30
Sidharth Vinod
3a12a63c32 Merge branch 'next' into sidv/tinyMermaid
* next: (269 commits)
  Resolves E2E testing issues and issue #5343
  Fix spelling
  Fix community integrations
  Fix docs
  docs: Fix config
  Update all minor dependencies
  Amend docs to document gitgraph parallel commits
  Fix lint
  Use Yarn Add COREPACK_ENABLE_STRICT
  Added link to Blazorade Mermaid to the community integrations page.
  Bump node version
  Add lcov to cspell
  Correcting path to docker-entrypoint.sh
  Update recommended Vitest extension
  Replace mermaid-js.github.io links
  Replace links to docs with links to webhelp
  Link to contributing page on webhelp
  Changes to timeline.md 1. Added colons to all 'NOTES' for consistency.
  Changes to timeline.md 1. Updates the Wikipedia citation to include a link. 2. Removed periods from documentation sections to be consistent (some had periods, some didn't) 3. Added a space to a coding example for spacing consistency.
  Replace version number placeholder
  ...
2024-03-01 12:48:22 +05:30
Sidharth Vinod
c1d31476cd Ignore node_modules 2024-01-24 09:44:25 +05:30
Sidharth Vinod
b23b97f612 Fix artifact upload 2024-01-24 09:41:00 +05:30
Sidharth Vinod
bd1789c54b Merge branch 'next' into sidv/tinyMermaid
* next: (562 commits)
  Lint
  Remove echo
  RefTest
  Echo event
  Update cypress
  Fix applitools
  Fix applitools
  docs: fix lint
  docs: move community to Discord
  Swap condition blocks to avoid using negation
  Reposition const declaration to ideal place
  Change repetitive values into consts
  docs: fix swimm link
  Fix Update Browserslist
  Use pnpm/action-setup@v2
  Fix lint
  Cleanup e2e.yml
  Ignore push events on merge queue
  Remove ::
  Remove ::
  ...
2024-01-24 09:25:52 +05:30
Sidharth Vinod
5feececff6 Merge branch 'next' into sidv/tinyMermaid
* next: (27 commits)
  chore: Fix type
  refactor!: remove MermaidConfig type enum fallback
  test: rewrite some `config` vals to tighten types
  chore: Add comment for `yy`.
  chore: Increase heap size when building
  chore: increase `test-util.ts` converage by returning `undefined`
  chore: add `vitest` imports to `test-util.ts`
  chore: run `pnpm lint:fix`
  create `noErrorsOrAlternatives` parser helper function
  chore: export `InfoModule` from `infoModule.ts`
  docs(parser): create `packages/parser` README.md file
  build: build `.langium` file using `generate` from `langium-cli`
  build: update `langium` and `langium-cli` to `v2.0.1`
  fix: fix if statment logic checks if `parser` is not `undefined`
  chore: add a comment illustrate why we build packages sequentially
  chore: refactore `&&` into `if` in `populateCommonDb`
  chore: remove `./*` part from `exports` in `parser/package.json`
  fix: use `execFileSync` instead of `execSync` in `generateLangium`
  fix(mermaid): mark `mermaid-parser` dependecy with `^`
  reorder `packages/parser` after `packages/mermaid/src/vitepress`
  ...
2023-09-08 16:43:32 +05:30
Sidharth Vinod
87b0025691 Merge branch 'develop' into sidv/tinyMermaid
* develop: (189 commits)
  Remove unnecessary tests
  Remove optional chaining
  chore: Update docs
  refactor: Use `||` instead of `??`
  Update flowchart.md (#4798)
  Update flowchart.md (#4792)
  core: Adapt changes from 3f7bafb2d7
  Update cypress/helpers/util.js
  chore: Update docs
  chore: Add deprecation notices, improve types
  chore: Cleanup gitGraph tests
  chore: Fix unit tests
  chore(deps): update all patch dependencies
  chore: Update docs
  Update docs
  New Mermaid Live Editor for Confluence Cloud (#4814)
  Update link to Discourse theme component (#4811)
  Update flowchart.md (#4810)
  chore: remove unneeded `CommomDB`
  chore: Update docs
  ...
2023-09-08 16:32:53 +05:30
Sidharth Vinod
e32747dc6f Merge branch 'next' into sidv/tinyMermaid
* next:
  Fixed wrong collapsible option at the left menu, updated vue
2023-08-20 00:35:17 +05:30
Sidharth Vinod
6936f6cd02 Merge branch 'next' into sidv/tinyMermaid
* next:
  chore: Move liveReload code into script.
  Fix minify undefined
2023-08-17 16:24:33 +05:30
Sidharth Vinod
841619a7d2 Merge branch 'next' into sidv/tinyMermaid
* next:
  chore: Move SVG import to comment.
  build docs
  Remove whitespace on empty line
  chore: Fix minify
  Documentation for #2509
  Update all minor dependencies
  Update all patch dependencies
  make more `RectData` required and remove optional assignment
  use lineBreakRegex in `svgDrawCommon`
  fix svgDrawCommon import by adding `.js`
  add types to `svgDrawCommon.ts`
  convert `svgDrawCommon` to TS
2023-08-17 12:41:11 +05:30
Sidharth Vinod
905cc365e7 chore: Fix ordering issue 2023-08-16 11:08:09 +05:30
Sidharth Vinod
55266c4085 chore: Simplify diagram exclusion
Co-authored-by: Alois Klink <alois@aloisklink.com>
2023-08-16 11:01:19 +05:30
Sidharth Vinod
5f95a26218 fix: Center version text in SVG 2023-08-14 14:31:37 +05:30
Sidharth Vinod
91b7d4234e chore: Highlight if tiny version is used in error and info. 2023-08-14 14:31:07 +05:30
Sidharth Vinod
0280316b03 Remove sourcemaps 2023-08-14 09:55:00 +05:30
Sidharth Vinod
7afe87bb52 Merge branch 'sidv/splitChunks' into sidv/tinyMermaid
* sidv/splitChunks:
  Fix import
2023-08-14 09:25:07 +05:30
Sidharth Vinod
9632049bf2 v11.0.0-alpha.3 2023-08-14 09:09:32 +05:30
Sidharth Vinod
13a6f04945 chore: Add vite support for define 2023-08-14 09:05:56 +05:30
Sidharth Vinod
58a744782a Merge branch 'sidv/splitChunks' into sidv/tinyMermaid
* sidv/splitChunks:
  chore: Fix outfile names
2023-08-14 08:58:29 +05:30
Sidharth Vinod
63d5808848 Merge branch 'sidv/splitChunks' into sidv/tinyMermaid
* sidv/splitChunks:
  chore: Add analyzer comment
  chore: Split chunks into folders
  chore: Split chunks into folders
  chore: Add defaultOptions to server
  chore: Split chunks into folders
2023-08-14 08:39:43 +05:30
Sidharth Vinod
a1541aa6f5 chore: Split chunks into folders 2023-08-14 08:14:43 +05:30
Sidharth Vinod
5f3c4fccaf chore: Add tiny bundle
Excludes elk and mindmap at build time
2023-08-14 07:34:16 +05:30
669 changed files with 43458 additions and 15982 deletions

View File

@@ -1,3 +1,9 @@
export interface PackageOptions {
name: string;
packageName: string;
file: string;
}
/**
* Shared common options for both ESBuild and Vite
*/
@@ -27,4 +33,9 @@ export const packageOptions = {
packageName: 'mermaid-layout-elk',
file: 'layouts.ts',
},
} as const;
examples: {
name: 'mermaid-examples',
packageName: 'examples',
file: 'index.ts',
},
} as const satisfies Record<string, PackageOptions>;

View File

@@ -19,6 +19,7 @@ const MERMAID_CONFIG_DIAGRAM_KEYS = [
'xyChart',
'requirement',
'mindmap',
'kanban',
'timeline',
'gitGraph',
'c4',
@@ -26,6 +27,7 @@ const MERMAID_CONFIG_DIAGRAM_KEYS = [
'block',
'packet',
'architecture',
'radar',
] as const;
/**

View File

@@ -10,13 +10,16 @@ const buildType = (packageName: string) => {
console.log(out.toString());
}
} catch (e) {
console.error(e);
if (e.stdout.length > 0) {
console.error(e.stdout.toString());
}
if (e.stderr.length > 0) {
console.error(e.stderr.toString());
}
// Exit the build process if we are in CI
if (process.env.CI) {
throw new Error(`Failed to build types for ${packageName}`);
}
}
};

View File

@@ -47,13 +47,13 @@ edgesep
EMPTYSTR
enddate
ERDIAGRAM
eslint
flatmap
forwardable
frontmatter
funs
gantt
GENERICTYPE
getBoundarys
grammr
graphtype
halign
@@ -88,6 +88,7 @@ NODIR
NSTR
outdir
Qcontrolx
QSTR
reinit
rels
reqs

View File

@@ -2,8 +2,10 @@
Ashish Jain
cpettitt
Dong Cai
knsv
Knut Sveidqvist
Nikolay Rozhkov
Peng Xiao
Per Brolin
Sidharth Vinod
subhash-halder
Vinod Sidharth

View File

@@ -26,6 +26,8 @@ dompurify
elkjs
fcose
fontawesome
Fonticons
Forgejo
Foswiki
Gitea
graphlib

View File

@@ -12,11 +12,11 @@ gantt
gitgraph
gzipped
handDrawn
knsv
Knut
kanban
marginx
marginy
Markdownish
mermaidchart
mermaidjs
mindmap
mindmaps
@@ -34,7 +34,6 @@ sandboxed
siebling
statediagram
substate
Sveidqvist
unfixable
Viewbox
viewports

View File

@@ -1,5 +1,5 @@
import { build } from 'esbuild';
import { mkdir, writeFile } from 'node:fs/promises';
import { cp, mkdir, readFile, rename, writeFile } from 'node:fs/promises';
import { packageOptions } from '../.build/common.js';
import { generateLangium } from '../.build/generateLangium.js';
import type { MermaidBuildOptions } from './util.js';
@@ -8,7 +8,10 @@ import { defaultOptions, getBuildConfig } from './util.js';
const shouldVisualize = process.argv.includes('--visualize');
const buildPackage = async (entryName: keyof typeof packageOptions) => {
const commonOptions: MermaidBuildOptions = { ...defaultOptions, entryName } as const;
const commonOptions: MermaidBuildOptions = {
...defaultOptions,
options: packageOptions[entryName],
} as const;
const buildConfigs: MermaidBuildOptions[] = [
// package.mjs
{ ...commonOptions },
@@ -28,6 +31,27 @@ const buildPackage = async (entryName: keyof typeof packageOptions) => {
// mermaid.js
{ ...iifeOptions },
// mermaid.min.js
{ ...iifeOptions, minify: true, metafile: shouldVisualize },
// mermaid.tiny.min.js
{
...iifeOptions,
minify: true,
includeLargeFeatures: false,
metafile: shouldVisualize,
sourcemap: false,
}
);
}
if (entryName === 'mermaid-zenuml') {
const iifeOptions: MermaidBuildOptions = {
...commonOptions,
format: 'iife',
globalName: 'mermaid-zenuml',
};
buildConfigs.push(
// mermaid-zenuml.js
{ ...iifeOptions },
// mermaid-zenuml.min.js
{ ...iifeOptions, minify: true, metafile: shouldVisualize }
);
}
@@ -40,7 +64,7 @@ const buildPackage = async (entryName: keyof typeof packageOptions) => {
continue;
}
const fileName = Object.keys(metafile.outputs)
.find((file) => !file.includes('chunks') && file.endsWith('js'))
.find((file) => !file.includes('chunks') && file.endsWith('js'))!
.replace('dist/', '');
// Upload metafile into https://esbuild.github.io/analyze/
await writeFile(`stats/${fileName}.meta.json`, JSON.stringify(metafile));
@@ -54,6 +78,21 @@ const handler = (e) => {
process.exit(1);
};
const buildTinyMermaid = async () => {
await mkdir('./packages/tiny/dist', { recursive: true });
await rename(
'./packages/mermaid/dist/mermaid.tiny.min.js',
'./packages/tiny/dist/mermaid.tiny.js'
);
// Copy version from mermaid's package.json to tiny's package.json
const mermaidPkg = JSON.parse(await readFile('./packages/mermaid/package.json', 'utf8'));
const tinyPkg = JSON.parse(await readFile('./packages/tiny/package.json', 'utf8'));
tinyPkg.version = mermaidPkg.version;
await writeFile('./packages/tiny/package.json', JSON.stringify(tinyPkg, null, 2) + '\n');
await cp('./packages/mermaid/CHANGELOG.md', './packages/tiny/CHANGELOG.md');
};
const main = async () => {
await generateLangium();
await mkdir('stats', { recursive: true });
@@ -62,6 +101,7 @@ const main = async () => {
for (const pkg of packageNames) {
await buildPackage(pkg).catch(handler);
}
await buildTinyMermaid();
};
void main();

View File

@@ -9,13 +9,18 @@ import { generateLangium } from '../.build/generateLangium.js';
import { defaultOptions, getBuildConfig } from './util.js';
const configs = Object.values(packageOptions).map(({ packageName }) =>
getBuildConfig({ ...defaultOptions, minify: false, core: false, entryName: packageName })
getBuildConfig({
...defaultOptions,
minify: false,
core: false,
options: packageOptions[packageName],
})
);
const mermaidIIFEConfig = getBuildConfig({
...defaultOptions,
minify: false,
core: false,
entryName: 'mermaid',
options: packageOptions.mermaid,
format: 'iife',
});
configs.push(mermaidIIFEConfig);

View File

@@ -3,7 +3,7 @@ import { fileURLToPath } from 'url';
import type { BuildOptions } from 'esbuild';
import { readFileSync } from 'fs';
import jsonSchemaPlugin from './jsonSchemaPlugin.js';
import { packageOptions } from '../.build/common.js';
import type { PackageOptions } from '../.build/common.js';
import { jisonPlugin } from './jisonPlugin.js';
const __dirname = fileURLToPath(new URL('.', import.meta.url));
@@ -13,14 +13,16 @@ export interface MermaidBuildOptions extends BuildOptions {
core: boolean;
metafile: boolean;
format: 'esm' | 'iife';
entryName: keyof typeof packageOptions;
options: PackageOptions;
includeLargeFeatures: boolean;
}
export const defaultOptions: Omit<MermaidBuildOptions, 'entryName'> = {
export const defaultOptions: Omit<MermaidBuildOptions, 'entryName' | 'options'> = {
minify: false,
metafile: false,
core: false,
format: 'esm',
includeLargeFeatures: true,
} as const;
const buildOptions = (override: BuildOptions): BuildOptions => {
@@ -39,12 +41,18 @@ const buildOptions = (override: BuildOptions): BuildOptions => {
};
};
const getFileName = (fileName: string, { core, format, minify }: MermaidBuildOptions) => {
const getFileName = (
fileName: string,
{ core, format, minify, includeLargeFeatures }: MermaidBuildOptions
) => {
if (core) {
fileName += '.core';
} else if (format === 'esm') {
fileName += '.esm';
}
if (!includeLargeFeatures) {
fileName += '.tiny';
}
if (minify) {
fileName += '.min';
}
@@ -52,20 +60,29 @@ const getFileName = (fileName: string, { core, format, minify }: MermaidBuildOpt
};
export const getBuildConfig = (options: MermaidBuildOptions): BuildOptions => {
const { core, entryName, metafile, format, minify } = options;
const {
core,
format,
options: { name, file, packageName },
globalName = 'mermaid',
includeLargeFeatures,
...rest
} = options;
const external: string[] = ['require', 'fs', 'path'];
const { name, file, packageName } = packageOptions[entryName];
const outFileName = getFileName(name, options);
const output: BuildOptions = buildOptions({
...rest,
absWorkingDir: resolve(__dirname, `../packages/${packageName}`),
entryPoints: {
[outFileName]: `src/${file}`,
},
metafile,
minify,
globalName,
logLevel: 'info',
chunkNames: `chunks/${outFileName}/[name]-[hash]`,
define: {
// This needs to be stringified for esbuild
includeLargeFeatures: `${includeLargeFeatures}`,
'import.meta.vitest': 'undefined',
},
});
@@ -84,11 +101,12 @@ export const getBuildConfig = (options: MermaidBuildOptions): BuildOptions => {
if (format === 'iife') {
output.format = 'iife';
output.splitting = false;
output.globalName = '__esbuild_esm_mermaid';
const originalGlobalName = output.globalName ?? 'mermaid';
output.globalName = `__esbuild_esm_mermaid_nm[${JSON.stringify(originalGlobalName)}]`;
// Workaround for removing the .default access in esbuild IIFE.
// https://github.com/mermaid-js/mermaid/pull/4109#discussion_r1292317396
output.footer = {
js: 'globalThis.mermaid = globalThis.__esbuild_esm_mermaid.default;',
js: `globalThis[${JSON.stringify(originalGlobalName)}] = globalThis.${output.globalName}.default;`,
};
output.outExtension = { '.js': '.js' };
} else {

View File

@@ -4,7 +4,7 @@ contact_links:
url: https://github.com/mermaid-js/mermaid/discussions
about: Ask the Community questions or share your own graphs in our discussions.
- name: Discord
url: https://discord.gg/AgrbSrBer3
url: https://discord.gg/sKeNQX4Wtj
about: Join our Community on Discord for Help and a casual chat.
- name: Documentation
url: https://mermaid.js.org

View File

@@ -29,7 +29,7 @@ body:
label: Colors
description: |-
A detailed list of the different colour values to use.
A list of currently used variable names can be found [here](https://mermaid-js.github.io/mermaid/#/theming?id=theme-variables-reference-table)
See the [list of currently used variable names](https://mermaid-js.github.io/mermaid/#/theming?id=theme-variables-reference-table)
placeholder: |-
- background: #f4f4f4
- primaryColor: #fff4dd

16
.github/lychee.toml vendored
View File

@@ -46,8 +46,20 @@ exclude = [
# Drupal 403
"https://(www.)?drupal.org",
# Swimm returns 404, eventhough the link is valid
"https://docs.swimm.io"
# Phbpp 403
"https://(www.)?phpbb.com",
# Swimm returns 404, even though the link is valid
"https://docs.swimm.io",
# Certificate Error
"https://noteshub.app",
# Timeout
"https://huehive.co",
"https://foswiki.org",
"https://www.gnu.org",
"https://mermaid-preview.com"
]
# Exclude all private IPs from checking.

2
.github/stale.yml vendored
View File

@@ -15,5 +15,5 @@ markComment: >
If you are still interested in this issue and it is still relevant you can comment to revive it.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: >
This issue has been been automatically closed due to a lack of activity.
This issue has been automatically closed due to a lack of activity.
This is done to maintain a clean list of issues that the community is interested in developing.

View File

@@ -13,13 +13,13 @@ jobs:
autofix:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
# uses version from "packageManager" field in package.json
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'
@@ -42,4 +42,4 @@ jobs:
working-directory: ./packages/mermaid
run: pnpm run docs:build
- uses: autofix-ci/action@ff86a557419858bb967097bfc916833f5647fa8c # main
- uses: autofix-ci/action@635ffb0c9798bd160680f18fd73371e355b85f27 # main

View File

@@ -18,12 +18,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'

View File

@@ -18,7 +18,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Check for difference in README.md and docs/README.md
run: |

View File

@@ -32,11 +32,11 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@2c779ab0d087cd7fe7b826087247c2c81f27bfa6 # v3.26.5
uses: github/codeql-action/init@b56ba49b26e50535fa1e7f7db0f4f7b4bf65d80d # v3.28.10
with:
config-file: ./.github/codeql/codeql-config.yml
languages: ${{ matrix.language }}
@@ -48,7 +48,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@2c779ab0d087cd7fe7b826087247c2c81f27bfa6 # v3.26.5
uses: github/codeql-action/autobuild@b56ba49b26e50535fa1e7f7db0f4f7b4bf65d80d # v3.28.10
# Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
@@ -62,4 +62,4 @@ jobs:
# make release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@2c779ab0d087cd7fe7b826087247c2c81f27bfa6 # v3.26.5
uses: github/codeql-action/analyze@b56ba49b26e50535fa1e7f7db0f4f7b4bf65d80d # v3.28.10

View File

@@ -15,6 +15,6 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Checkout Repository'
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: 'Dependency Review'
uses: actions/dependency-review-action@5a2ce3f5b92ee19cbb1541a4984c76d921601d7c # v4.3.4
uses: actions/dependency-review-action@3b139cfc5fae8b618d3eae3675e383bb1769c019 # v4.5.0

View File

@@ -32,29 +32,31 @@ jobs:
run: |
echo "::error,title=Not using Applitools::APPLITOOLS_API_KEY is empty, disabling Applitools for this run."
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
# uses version from "packageManager" field in package.json
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
node-version-file: '.node-version'
- if: ${{ env.USE_APPLI }}
name: Notify applitools of new batch
# Copied from docs https://applitools.com/docs/topics/integrations/github-integration-ci-setup.html
run: curl -L -d '' -X POST "$APPLITOOLS_SERVER_URL/api/externals/github/push?apiKey=$APPLITOOLS_API_KEY&CommitSha=$GITHUB_SHA&BranchName=${APPLITOOLS_BRANCH}$&ParentBranchName=$APPLITOOLS_PARENT_BRANCH"
env:
# e.g. mermaid-js/mermaid/my-branch
APPLITOOLS_BRANCH: ${{ github.repository }}/${{ github.ref_name }}
APPLITOOLS_PARENT_BRANCH: ${{ github.event.inputs.parent_branch }}
APPLITOOLS_API_KEY: ${{ secrets.APPLITOOLS_API_KEY }}
APPLITOOLS_SERVER_URL: 'https://eyesapi.applitools.com'
uses: wei/curl@012398a392d02480afa2720780031f8621d5f94c
with:
args: -X POST "$APPLITOOLS_SERVER_URL/api/externals/github/push?apiKey=$APPLITOOLS_API_KEY&CommitSha=$GITHUB_SHA&BranchName=${APPLITOOLS_BRANCH}$&ParentBranchName=$APPLITOOLS_PARENT_BRANCH"
- name: Cypress run
uses: cypress-io/github-action@d79d2d530a66e641eb4a5f227e13bc985c60b964 # v4.2.2
uses: cypress-io/github-action@18a6541367f4580a515371905f499a27a44e8dbe # v6.7.12
id: cypress
with:
start: pnpm run dev

70
.github/workflows/e2e-timings.yml vendored Normal file
View File

@@ -0,0 +1,70 @@
name: E2E - Generate Timings
on:
# run this workflow every night at 3am
schedule:
- cron: '28 3 * * *'
# or when the user triggers it from GitHub Actions page
workflow_dispatch:
concurrency: ${{ github.workflow }}-${{ github.ref }}
permissions:
contents: write
pull-requests: write
jobs:
timings:
runs-on: ubuntu-latest
container:
image: cypress/browsers:node-20.11.0-chrome-121.0.6167.85-1-ff-120.0-edge-121.0.2277.83-1
options: --user 1001
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
node-version-file: '.node-version'
- name: Install dependencies
uses: cypress-io/github-action@18a6541367f4580a515371905f499a27a44e8dbe # v6.7.12
with:
runTests: false
- name: Cypress run
uses: cypress-io/github-action@18a6541367f4580a515371905f499a27a44e8dbe # v6.7.12
id: cypress
with:
install: false
start: pnpm run dev:coverage
wait-on: 'http://localhost:9000'
browser: chrome
publish-summary: false
env:
VITEST_COVERAGE: true
CYPRESS_COMMIT: ${{ github.sha }}
SPLIT: 1
SPLIT_INDEX: 0
SPLIT_FILE: 'cypress/timings.json'
- name: Compare timings
id: compare
run: |
OUTPUT=$(pnpm tsx scripts/compare-timings.ts)
echo "$OUTPUT" >> $GITHUB_STEP_SUMMARY
echo "output<<EOF" >> $GITHUB_OUTPUT
echo "$OUTPUT" >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT
- name: Commit and create pull request
uses: peter-evans/create-pull-request@889dce9eaba7900ce30494f5e1ac7220b27e5c81
with:
add-paths: |
cypress/timings.json
commit-message: 'chore: update E2E timings'
branch: update-timings
title: Update E2E Timings
body: ${{ steps.compare.outputs.output }}
delete-branch: true
sign-commits: true

View File

@@ -28,7 +28,8 @@ env:
) ||
github.event.before
}}
shouldRunParallel: ${{ secrets.CYPRESS_RECORD_KEY != '' && !(github.event_name == 'push' && github.ref == 'refs/heads/develop') }}
RUN_VISUAL_TEST: >-
${{ github.repository == 'mermaid-js/mermaid' && (github.event_name != 'pull_request' || !startsWith(github.head_ref, 'renovate/')) }}
jobs:
cache:
runs-on: ubuntu-latest
@@ -36,30 +37,29 @@ jobs:
image: cypress/browsers:node-20.11.0-chrome-121.0.6167.85-1-ff-120.0-edge-121.0.2277.83-1
options: --user 1001
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
node-version-file: '.node-version'
- name: Cache snapshots
id: cache-snapshot
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
uses: actions/cache@0c907a75c2c80ebcb7f088228285e798b750cf8f # v4.2.1
with:
save-always: true
path: ./cypress/snapshots
key: ${{ runner.os }}-snapshots-${{ env.targetHash }}
# If a snapshot for a given Hash is not found, we checkout that commit, run the tests and cache the snapshots.
- name: Switch to base branch
if: ${{ steps.cache-snapshot.outputs.cache-hit != 'true' }}
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: ${{ env.targetHash }}
- name: Install dependencies
if: ${{ steps.cache-snapshot.outputs.cache-hit != 'true' }}
uses: cypress-io/github-action@df7484c5ba85def7eef30db301afa688187bc378 # v6.7.2
uses: cypress-io/github-action@18a6541367f4580a515371905f499a27a44e8dbe # v6.7.12
with:
# just perform install
runTests: false
@@ -80,28 +80,28 @@ jobs:
strategy:
fail-fast: false
matrix:
containers: [1, 2, 3, 4]
containers: [1, 2, 3, 4, 5]
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
# uses version from "packageManager" field in package.json
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
node-version-file: '.node-version'
# These cached snapshots are downloaded, providing the reference snapshots.
- name: Cache snapshots
id: cache-snapshot
uses: actions/cache/restore@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
uses: actions/cache/restore@0c907a75c2c80ebcb7f088228285e798b750cf8f # v4.2.1
with:
path: ./cypress/snapshots
key: ${{ runner.os }}-snapshots-${{ env.targetHash }}
- name: Install dependencies
uses: cypress-io/github-action@df7484c5ba85def7eef30db301afa688187bc378 # v6.7.2
uses: cypress-io/github-action@18a6541367f4580a515371905f499a27a44e8dbe # v6.7.12
with:
runTests: false
@@ -117,11 +117,8 @@ jobs:
# Install NPM dependencies, cache them correctly
# and run all Cypress tests
- name: Cypress run
uses: cypress-io/github-action@df7484c5ba85def7eef30db301afa688187bc378 # v6.7.2
uses: cypress-io/github-action@18a6541367f4580a515371905f499a27a44e8dbe # v6.7.12
id: cypress
# If CYPRESS_RECORD_KEY is set, run in parallel on all containers
# Otherwise (e.g. if running from fork), we run on a single container only
if: ${{ env.shouldRunParallel == 'true' || ( matrix.containers == 1 ) }}
with:
install: false
start: pnpm run dev:coverage
@@ -129,19 +126,20 @@ jobs:
browser: chrome
# Disable recording if we don't have an API key
# e.g. if this action was run from a fork
record: ${{ env.shouldRunParallel == 'true' }}
parallel: ${{ env.shouldRunParallel == 'true' }}
record: ${{ env.RUN_VISUAL_TEST == 'true' && secrets.CYPRESS_RECORD_KEY != '' }}
env:
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
VITEST_COVERAGE: true
ARGOS_PARALLEL: ${{ env.RUN_VISUAL_TEST == 'true' }}
ARGOS_PARALLEL_TOTAL: ${{ env.RUN_VISUAL_TEST == 'true' && strategy.job-total || 1 }}
ARGOS_PARALLEL_INDEX: ${{ env.RUN_VISUAL_TEST == 'true' && matrix.containers || 1 }}
CYPRESS_COMMIT: ${{ github.sha }}
ARGOS_TOKEN: ${{ secrets.ARGOS_TOKEN }}
ARGOS_PARALLEL: ${{ env.shouldRunParallel == 'true' }}
ARGOS_PARALLEL_TOTAL: 4
ARGOS_PARALLEL_INDEX: ${{ matrix.containers }}
CYPRESS_RECORD_KEY: ${{ env.RUN_VISUAL_TEST == 'true' && secrets.CYPRESS_RECORD_KEY || ''}}
SPLIT: ${{ strategy.job-total }}
SPLIT_INDEX: ${{ strategy.job-index }}
SPLIT_FILE: 'cypress/timings.json'
VITEST_COVERAGE: true
- name: Upload Coverage to Codecov
uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0
uses: codecov/codecov-action@13ce06bfc6bbe3ecf90edbbf1bc32fe5978ca1d3 # v5.3.1
# Run step only pushes to develop and pull_requests
if: ${{ steps.cypress.conclusion == 'success' && (github.event_name == 'pull_request' || github.ref == 'refs/heads/develop')}}
with:

View File

@@ -29,17 +29,17 @@ jobs:
# lychee only uses the GITHUB_TOKEN to avoid rate-limiting
contents: read
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Restore lychee cache
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
uses: actions/cache@0c907a75c2c80ebcb7f088228285e798b750cf8f # v4.2.1
with:
path: .lycheecache
key: cache-lychee-${{ github.sha }}
restore-keys: cache-lychee-
- name: Link Checker
uses: lycheeverse/lychee-action@c053181aa0c3d17606addfe97a9075a32723548a # v1.9.3
uses: lycheeverse/lychee-action@f613c4a64e50d792e0b31ec34bbcbba12263c6a6 # v2.3.0
with:
args: >-
--config .github/lychee.toml

View File

@@ -15,7 +15,7 @@ jobs:
docker-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: hadolint/hadolint-action@54c9adbab1582c2ef04b2016b760714a4bfde3cf # v3.1.0
with:
@@ -23,13 +23,13 @@ jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
# uses version from "packageManager" field in package.json
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'

View File

@@ -22,10 +22,36 @@ jobs:
pull-requests: write # write permission is required to label PRs
steps:
- name: Label PR
uses: release-drafter/release-drafter@3f0f87098bd6b5c5b9a36d49c41d998ea58f9348 # v6.0.0
uses: release-drafter/release-drafter@b1476f6e6eb133afa41ed8589daba6dc69b4d3f5 # v6.1.0
with:
config-name: pr-labeler.yml
disable-autolabeler: false
disable-releaser: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Add "Sponsored by MermaidChart" label
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const prNumber = context.payload.pull_request.number;
const { data: commits } = await github.rest.pulls.listCommits({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: prNumber,
});
const isSponsored = commits.every(
(c) => c.commit.author.email?.endsWith('@mermaidchart.com')
);
if (isSponsored) {
console.log('PR is sponsored. Adding label.');
await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: prNumber,
labels: ['Sponsored by MermaidChart'],
});
}

View File

@@ -23,12 +23,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'
@@ -37,7 +37,7 @@ jobs:
run: pnpm install --frozen-lockfile
- name: Setup Pages
uses: actions/configure-pages@1f0c5cde4bc74cd7e1254d0cb4de8d49e9068c7d # v4.0.0
uses: actions/configure-pages@983d7736d9b0ae728b81ab479565c72886d7745b # v5.0.0
- name: Run Build
run: pnpm --filter mermaid run docs:build:vitepress

View File

@@ -9,14 +9,14 @@ jobs:
publish-preview:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'

View File

@@ -26,12 +26,12 @@ jobs:
timeout-minutes: 5
steps:
- name: Checkout Repo
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'

View File

@@ -21,12 +21,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'
@@ -36,7 +36,7 @@ jobs:
- name: Create Release Pull Request or Publish to npm
id: changesets
uses: changesets/action@aba318e9165b45b7948c60273e0b72fce0a64eb9 # v1.4.7
uses: changesets/action@c8bada60c408975afd1a20b3db81d6eee6789308 # v1.4.9
with:
version: pnpm changeset:version
publish: pnpm changeset:publish

View File

@@ -16,22 +16,22 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: Run analysis
uses: ossf/scorecard-action@0864cf19026789058feabb7e87baa5f140aac736 # v2.3.1
uses: ossf/scorecard-action@f49aabe0b5af0936a0987cfb85d86b75731b0186 # v2.4.1
with:
results_file: results.sarif
results_format: sarif
publish_results: true
- name: Upload artifact
uses: actions/upload-artifact@97a0fba1372883ab732affbe8f94b823f91727db # v3.pre.node20
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
with:
name: SARIF file
path: results.sarif
retention-days: 5
- name: Upload to code-scanning
uses: github/codeql-action/upload-sarif@f0f3afee809481da311ca3a6ff1ff51d81dbeb24 # v3.26.4
uses: github/codeql-action/upload-sarif@b56ba49b26e50535fa1e7f7db0f4f7b4bf65d80d # v3.28.10
with:
sarif_file: results.sarif

View File

@@ -9,13 +9,13 @@ jobs:
unit-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
# uses version from "packageManager" field in package.json
- name: Setup Node.js
uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b # v4.0.3
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
cache: pnpm
node-version-file: '.node-version'
@@ -43,7 +43,7 @@ jobs:
pnpm test:check:tsc
- name: Upload Coverage to Codecov
uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0
uses: codecov/codecov-action@13ce06bfc6bbe3ecf90edbbf1bc32fe5978ca1d3 # v5.3.1
# Run step only pushes to develop and pull_requests
if: ${{ github.event_name == 'pull_request' || github.ref == 'refs/heads/develop' }}
with:

View File

@@ -8,8 +8,8 @@ jobs:
update-browser-list:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- run: npx update-browserslist-db@latest
- name: Commit changes
uses: EndBug/add-and-commit@a94899bca583c204427a224a7af87c02f9b325d5 # v9.1.4
@@ -19,7 +19,7 @@ jobs:
message: 'chore: update browsers list'
push: false
- name: Create Pull Request
uses: peter-evans/create-pull-request@c5a7806660adbe173f04e3e038b0ccdcd758773c # v6.1.0
uses: peter-evans/create-pull-request@67ccf781d68cd99b580ae25a5c18a1cc84ffff1f # v7.0.6
with:
branch: update-browserslist
title: Update Browserslist

70
.github/workflows/validate-lockfile.yml vendored Normal file
View File

@@ -0,0 +1,70 @@
name: Validate pnpm-lock.yaml
on:
pull_request:
paths:
- 'pnpm-lock.yaml'
- '**/package.json'
- '.github/workflows/validate-lockfile.yml'
jobs:
validate-lockfile:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
- uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
- name: Validate pnpm-lock.yaml entries
id: validate # give this step an ID so we can reference its outputs
run: |
issues=()
# 1) No tarball references
if grep -qF 'tarball:' pnpm-lock.yaml; then
issues+=("• Tarball references found (forbidden)")
fi
# 2) No unwanted vitepress paths
if grep -qF 'packages/mermaid/src/vitepress' pnpm-lock.yaml; then
issues+=("• Disallowed path 'packages/mermaid/src/vitepress' present. Run `rm -rf packages/mermaid/src/vitepress && pnpm install` to regenerate.")
fi
# 3) Lockfile only changes when package.json changes
git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.sha }} > changed.txt
if grep -q '^pnpm-lock.yaml$' changed.txt && ! grep -q 'package.json' changed.txt; then
issues+=("• pnpm-lock.yaml changed without any package.json modification")
fi
# If any issues, output them and fail
if [ ${#issues[@]} -gt 0 ]; then
# Use the new GITHUB_OUTPUT approach to set a multiline output
{
echo "errors<<EOF"
printf '%s\n' "${issues[@]}"
echo "EOF"
} >> $GITHUB_OUTPUT
exit 1
fi
- name: Comment on PR if validation failed
if: failure()
uses: peter-evans/create-or-update-comment@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
issue-number: ${{ github.event.pull_request.number }}
body: |
The following issue(s) were detected:
${{ steps.validate.outputs.errors }}
Please address these and push an update.
_Posted automatically by GitHub Actions_

View File

@@ -1 +1 @@
20.12.2
22.14.0

View File

@@ -94,6 +94,10 @@ export const getBuildConfig = ({ minify, core, watch, entryName }: BuildOptions)
}),
...visualizerOptions(packageName, core),
],
define: {
// Needs to be string
includeLargeFeatures: 'true',
},
};
if (watch && config.build) {

View File

@@ -256,7 +256,7 @@ mermaid.run({
- Problem showing graph with php on localhost [\#502](https://github.com/knsv/mermaid/issues/502)
- logLevel's option doesnt work at 7.0.0 [\#501](https://github.com/knsv/mermaid/issues/501)
- How do I get the log for a render or parse attempt? [\#500](https://github.com/knsv/mermaid/issues/500)
- Mermaid neutral style style to built in latest release [\#499](https://github.com/knsv/mermaid/issues/499)
- Mermaid neutral style to built in latest release [\#499](https://github.com/knsv/mermaid/issues/499)
- Any plans for adding a typescript definition file? [\#495](https://github.com/knsv/mermaid/issues/495)
- Gantt diagrams too narrow [\#493](https://github.com/knsv/mermaid/issues/493)
- Flowchart edge labels placement [\#490](https://github.com/knsv/mermaid/issues/490)
@@ -833,7 +833,7 @@ mermaid.run({
- Merge pull request \#1 from knsv/master [\#96](https://github.com/knsv/mermaid/pull/96) ([gkchic](https://github.com/gkchic))
- Removed duplicated section in flowchart docs [\#94](https://github.com/knsv/mermaid/pull/94) ([kaime](https://github.com/kaime))
- Grammar changes to sequence page [\#93](https://github.com/knsv/mermaid/pull/93) ([gkchic](https://github.com/gkchic))
- Github buttons [\#89](https://github.com/knsv/mermaid/pull/89) ([gkchic](https://github.com/gkchic))
- GitHub buttons [\#89](https://github.com/knsv/mermaid/pull/89) ([gkchic](https://github.com/gkchic))
- Template change [\#88](https://github.com/knsv/mermaid/pull/88) ([gkchic](https://github.com/gkchic))
## [0.3.1](https://github.com/knsv/mermaid/tree/0.3.1) (2015-01-05)
@@ -1002,4 +1002,4 @@ mermaid.run({
## [0.1.0](https://github.com/knsv/mermaid/tree/0.1.0) (2014-11-16)
\* _This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)_
\* _This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/GitHub-Changelog-Generator)_

View File

@@ -1,4 +1,4 @@
FROM node:20.12.2-alpine3.19@sha256:7a91aa397f2e2dfbfcdad2e2d72599f374e0b0172be1d86eeb73f1d33f36a4b2
FROM node:22.12.0-alpine3.19@sha256:40dc4b415c17b85bea9be05314b4a753f45a4e1716bb31c01182e6c53d51a654
USER 0:0

View File

@@ -15,7 +15,7 @@ Generate diagrams from markdown-like text.
<a href="https://mermaid.live/"><b>Live Editor!</b></a>
</p>
<p align="center">
<a href="https://mermaid.js.org">📖 Documentation</a> | <a href="https://mermaid.js.org/intro/">🚀 Getting Started</a> | <a href="https://www.jsdelivr.com/package/npm/mermaid">🌐 CDN</a> | <a href="https://discord.gg/AgrbSrBer3" title="Discord invite">🙌 Join Us</a>
<a href="https://mermaid.js.org">📖 Documentation</a> | <a href="https://mermaid.js.org/intro/">🚀 Getting Started</a> | <a href="https://www.jsdelivr.com/package/npm/mermaid">🌐 CDN</a> | <a href="https://discord.gg/sKeNQX4Wtj" title="Discord invite">🙌 Join Us</a>
</p>
<p align="center">
<a href="./README.zh-CN.md">简体中文</a>
@@ -33,7 +33,7 @@ Try Live Editor previews of future releases: <a href="https://develop.git.mermai
[![Coverage Status](https://codecov.io/github/mermaid-js/mermaid/branch/develop/graph/badge.svg)](https://app.codecov.io/github/mermaid-js/mermaid/tree/develop)
[![CDN Status](https://img.shields.io/jsdelivr/npm/hm/mermaid)](https://www.jsdelivr.com/package/npm/mermaid)
[![NPM Downloads](https://img.shields.io/npm/dm/mermaid)](https://www.npmjs.com/package/mermaid)
[![Join our Discord!](https://img.shields.io/static/v1?message=join%20chat&color=9cf&logo=discord&label=discord)](https://discord.gg/AgrbSrBer3)
[![Join our Discord!](https://img.shields.io/static/v1?message=join%20chat&color=9cf&logo=discord&label=discord)](https://discord.gg/sKeNQX4Wtj)
[![Twitter Follow](https://img.shields.io/badge/Social-mermaidjs__-blue?style=social&logo=X)](https://twitter.com/mermaidjs_)
[![Covered by Argos Visual Testing](https://argos-ci.com/badge.svg)](https://argos-ci.com?utm_source=mermaid&utm_campaign=oss)
[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/mermaid-js/mermaid/badge)](https://securityscorecards.dev/viewer/?uri=github.com/mermaid-js/mermaid)
@@ -44,7 +44,7 @@ Try Live Editor previews of future releases: <a href="https://develop.git.mermai
**Thanks to all involved, people committing pull requests, people answering questions! 🙏**
<a href="https://mermaid.js.org/landing/"><img src="https://github.com/mermaid-js/mermaid/blob/master/docs/intro/img/book-banner-post-release.jpg" alt="Explore Mermaid.js in depth, with real-world examples, tips & tricks from the creator... The first official book on Mermaid is available for purchase. Check it out!"></a>
<a href="https://mermaid.js.org/landing/"><img src="https://github.com/mermaid-js/mermaid/blob/master/docs/intro/img/book-banner-post-release.jpg" alt='Banner for "The Official Guide to Mermaid.js" book'></a>
## Table of content
@@ -253,6 +253,34 @@ pie
### Git graph [experimental - <a href="https://mermaid.live/edit#pako:eNqNkMFugzAMhl8F-VyVAR1tOW_aA-zKxSSGRCMJCk6lCvHuNZPKZdM0n-zf3_8r8QIqaIIGMqnB8kfEybQ--y4VnLP8-9RF9Mpkmm40hmlnDKmvkPiH_kfS7nFo_VN0FAf6XwocQGgxa_nGsm1bYEOOWmik1dRjGrmF1q-Cpkkj07u2HCI0PY4zHQATh8-7V9BwTPSE3iwOEd1OjQE1iWkBvk_bzQY7s0Sq4Hs7bHqKo8iGeZqbPN_WR7mpSd1RHpvPVhuMbG7XOq_L-oJlRfW5wteq0qorrpe-PBW9Pr8UJcK6rg-BLYPQ">live editor</a>]
```
gitGraph
commit
commit
branch develop
checkout develop
commit
commit
checkout main
merge develop
commit
commit
```
```mermaid
gitGraph
commit
commit
branch develop
checkout develop
commit
commit
checkout main
merge develop
commit
commit
```
### Bar chart (using gantt chart) [<a href="https://mermaid.js.org/syntax/gantt.html">docs</a> - <a href="https://mermaid.live/edit#pako:eNptkU1vhCAQhv8KIenNugiI4rkf6bmXpvEyFVxJFDYyNt1u9r8X63Z7WQ9m5pknLzieaBeMpQ3dg0dsPUkPOhwteXZIXmJcbCT3xMAxkuh8Z8kIEclyMIB209fqKcwTICFvG4IvFy_oLrZ-g9F26ILfQgvNFN94VaRXQ1iWqpumZBcu1J8p1E1TXDx59eQNr5LyEqjJn6hv5QnGNlxevZJmdLLpy5xJSzut45biYCfb0iaVxvawjNjS1p-TCguG16PvaIPzYjO67e3BwX6GiTY9jPFKH43DMF_hGMDY1J4oHg-_f8hFTJFd8L3br3yZx4QHxENsdrt1nO8dDstH3oVpF50ZYMbhU6ud4qoGLqyqBJRCmO6j0HXPZdGbihUc6Pmc0QP49xD-b5X69ZQv2gjO81IwzWqhC1lKrjJ6pA3nVS7SMiVjrKirWlYp5fs3osgrWeo00lorLWvOzz8JVbXm">live editor</a>]
```
@@ -419,7 +447,7 @@ For public sites, it can be precarious to retrieve text from users on the intern
As an extra level of security for sites with external users we are happy to introduce a new security level in which the diagram is rendered in a sandboxed iframe preventing javascript in the code from being executed. This is a great step forward for better security.
_Unfortunately you can not have a cake and eat it at the same time which in this case means that some of the interactive functionality gets blocked along with the possible malicious code._
_Unfortunately you cannot have a cake and eat it at the same time which in this case means that some of the interactive functionality gets blocked along with the possible malicious code._
## Reporting vulnerabilities
@@ -435,7 +463,7 @@ A quick note from Knut Sveidqvist:
>
> _Thank you to [Tyler Long](https://github.com/tylerlong) who has been a collaborator since April 2017._
>
> _Thank you to the ever-growing list of [contributors](https://github.com/knsv/mermaid/graphs/contributors) that brought the project this far!_
> _Thank you to the ever-growing list of [contributors](https://github.com/mermaid-js/mermaid/graphs/contributors) that brought the project this far!_
---

View File

@@ -15,7 +15,7 @@ Mermaid
<a href="https://mermaid.live/"><b>实时编辑器!</b></a>
</p>
<p align="center">
<a href="https://mermaid.js.org">📖 文档</a> | <a href="https://mermaid.js.org/intro/">🚀 入门</a> | <a href="https://www.jsdelivr.com/package/npm/mermaid">🌐 CDN</a> | <a href="https://discord.gg/AgrbSrBer3" title="Discord invite">🙌 加入我们</a>
<a href="https://mermaid.js.org">📖 文档</a> | <a href="https://mermaid.js.org/intro/">🚀 入门</a> | <a href="https://www.jsdelivr.com/package/npm/mermaid">🌐 CDN</a> | <a href="https://discord.gg/sKeNQX4Wtj" title="Discord invite">🙌 加入我们</a>
</p>
<p align="center">
<a href="./README.md">English</a>
@@ -34,7 +34,7 @@ Mermaid
[![Coverage Status](https://codecov.io/github/mermaid-js/mermaid/branch/develop/graph/badge.svg)](https://app.codecov.io/github/mermaid-js/mermaid/tree/develop)
[![CDN Status](https://img.shields.io/jsdelivr/npm/hm/mermaid)](https://www.jsdelivr.com/package/npm/mermaid)
[![NPM Downloads](https://img.shields.io/npm/dm/mermaid)](https://www.npmjs.com/package/mermaid)
[![Join our Discord!](https://img.shields.io/static/v1?message=join%20chat&color=9cf&logo=discord&label=discord)](https://discord.gg/AgrbSrBer3)
[![Join our Discord!](https://img.shields.io/static/v1?message=join%20chat&color=9cf&logo=discord&label=discord)](https://discord.gg/sKeNQX4Wtj)
[![Twitter Follow](https://img.shields.io/badge/Social-mermaidjs__-blue?style=social&logo=X)](https://twitter.com/mermaidjs_)
<img src="./img/header.png" alt="" />
@@ -43,13 +43,13 @@ Mermaid
**感谢所有参与进来提交 PR解答疑问的人们! 🙏**
<a href="https://mermaid.js.org/landing/"><img src="https://github.com/mermaid-js/mermaid/blob/master/docs/intro/img/book-banner-post-release.jpg" alt="Explore Mermaid.js in depth, with real-world examples, tips & tricks from the creator... The first official book on Mermaid is available for purchase. Check it out!"></a>
<a href="https://mermaid.js.org/landing/"><img src="https://github.com/mermaid-js/mermaid/blob/master/docs/intro/img/book-banner-post-release.jpg" alt='Banner for "The Official Guide to Mermaid.js" book'></a>
## 关于 Mermaid
<!-- <Main description> -->
Mermaid 是一个基于 Javascript 的图表绘制工具,通过解析类 Markdown 的文本语法来实现图表的创建和动态修改。Mermaid 诞生的主要目的是让文档的更新能够及时跟上开发进度。
Mermaid 是一个基于 JavaScript 的图表绘制工具,通过解析类 Markdown 的文本语法来实现图表的创建和动态修改。Mermaid 诞生的主要目的是让文档的更新能够及时跟上开发进度。
> Doc-Rot 是 Mermaid 致力于解决的一个难题。
@@ -358,7 +358,7 @@ _很不幸的是鱼与熊掌不可兼得在这个场景下它意味着在
> _特别感谢 [d3](https://d3js.org/) 和 [dagre-d3](https://github.com/cpettitt/dagre-d3) 这两个优秀的项目它们提供了图形布局和绘图工具库_ > _同样感谢 [js-sequence-diagram](https://bramp.github.io/js-sequence-diagrams) 提供了时序图语法的使用。 感谢 Jessica Peter 提供了甘特图渲染的灵感。_ > _感谢 [Tyler Long](https://github.com/tylerlong) 从 2017 年四月开始成为了项目的合作者。_
>
> _感谢越来越多的 [贡献者们](https://github.com/knsv/mermaid/graphs/contributors)没有你们就没有这个项目的今天_
> _感谢越来越多的 [贡献者们](https://github.com/mermaid-js/mermaid/graphs/contributors)没有你们就没有这个项目的今天_
---

View File

@@ -1,13 +0,0 @@
import { MockedD3 } from '../packages/mermaid/src/tests/MockedD3.js';
export const select = function () {
return new MockedD3();
};
export const selectAll = function () {
return new MockedD3();
};
export const curveBasis = 'basis';
export const curveLinear = 'linear';
export const curveCardinal = 'cardinal';

View File

@@ -1,8 +1,9 @@
import { defineConfig } from 'cypress';
import { addMatchImageSnapshotPlugin } from 'cypress-image-snapshot/plugin';
import coverage from '@cypress/code-coverage/task';
import eyesPlugin from '@applitools/eyes-cypress';
import { registerArgosTask } from '@argos-ci/cypress/task';
import coverage from '@cypress/code-coverage/task.js';
import { defineConfig } from 'cypress';
import { addMatchImageSnapshotPlugin } from 'cypress-image-snapshot/plugin.js';
import cypressSplit from 'cypress-split';
export default eyesPlugin(
defineConfig({
@@ -13,6 +14,7 @@ export default eyesPlugin(
specPattern: 'cypress/integration/**/*.{js,ts}',
setupNodeEvents(on, config) {
coverage(on, config);
cypressSplit(on, config);
on('before:browser:launch', (browser, launchOptions) => {
if (browser.name === 'chrome' && browser.isHeadless) {
launchOptions.args.push('--window-size=1440,1024', '--force-device-scale-factor=1');
@@ -21,11 +23,12 @@ export default eyesPlugin(
});
// copy any needed variables from process.env to config.env
config.env.useAppli = process.env.USE_APPLI ? true : false;
config.env.useArgos = !!process.env.CI;
config.env.useArgos = process.env.RUN_VISUAL_TEST === 'true';
if (config.env.useArgos) {
registerArgosTask(on, config, {
token: 'fc3a35cf5200db928d65b2047861582d9444032b',
// Enable upload to Argos only when it runs on CI.
uploadToArgos: !!process.env.CI,
});
} else {
addMatchImageSnapshotPlugin(on, config);

View File

@@ -29,6 +29,7 @@ export const mermaidUrl = (
options: CypressMermaidConfig,
api: boolean
): string => {
options.handDrawnSeed = 1;
const codeObject: CodeObject = {
code: graphStr,
mermaid: options,
@@ -131,3 +132,10 @@ export const verifyScreenshot = (name: string): void => {
cy.matchImageSnapshot(name);
}
};
export const verifyNumber = (value: number, expected: number, deltaPercent = 10): void => {
expect(value).to.be.within(
expected * (1 - deltaPercent / 100),
expected * (1 + deltaPercent / 100)
);
};

View File

@@ -69,7 +69,9 @@ describe('Configuration', () => {
.and('include', 'url(#');
});
});
it('should handle arrowMarkerAbsolute explicitly set to "false" as false', () => {
// This has been broken for a long time, but something about the Cypress environment was
// rewriting the URL to be relative, causing the test to incorrectly pass.
it.skip('should handle arrowMarkerAbsolute explicitly set to "false" as false', () => {
renderGraph(
`graph TD
A[Christmas] -->|Get money| B(Go shopping)
@@ -112,7 +114,7 @@ describe('Configuration', () => {
.first()
.should('have.attr', 'marker-end')
.should('exist')
.and('include', 'url(http://localhost');
.and('include', 'url(http\\:\\/\\/localhost');
});
});
it('should not taint the initial configuration when using multiple directives', () => {

View File

@@ -20,7 +20,7 @@ describe('Interaction', () => {
});
it('Graph: should handle a click on a node with a bound url', () => {
// When there is a URL, cy.contains selects the a tag instead of the span. The .node is a child of a, so we have to use find instead of parent.
// When there is a URL, `cy.contains()` selects the `a` tag instead of the `span` tag. The .node is a child of `a`, so we have to use `find()` instead of `parent`.
cy.contains('URLTest1').find('.node').click();
cy.location().should(({ href }) => {
expect(href).to.eq('http://localhost:9000/empty.html');
@@ -146,7 +146,7 @@ describe('Interaction', () => {
});
});
describe('Interaction - security level other, missspelling', () => {
describe('Interaction - security level other, misspelling', () => {
beforeEach(() => {
cy.visit('http://localhost:9000/click_security_other.html');
});

View File

@@ -19,6 +19,25 @@ describe.skip('architecture diagram', () => {
`
);
});
it('should render a simple architecture diagram with titleAndAccessibilities', () => {
imgSnapshotTest(
`architecture-beta
title Simple Architecture Diagram
accTitle: Accessibility Title
accDescr: Accessibility Description
group api(cloud)[API]
service db(database)[Database] in api
service disk1(disk)[Storage] in api
service disk2(disk)[Storage] in api
service server(server)[Server] in api
db:L -- R:server
disk1:T -- B:server
disk2:T -- B:db
`
);
});
it('should render an architecture diagram with groups within groups', () => {
imgSnapshotTest(
`architecture-beta
@@ -171,9 +190,62 @@ describe.skip('architecture diagram', () => {
`
);
});
it('should render an architecture diagram with a reasonable height', () => {
imgSnapshotTest(
`architecture-beta
group federated(cloud)[Federated Environment]
service server1(server)[System] in federated
service edge(server)[Edge Device] in federated
server1:R -- L:edge
group on_prem(cloud)[Hub]
service firewall(server)[Firewall Device] in on_prem
service server(server)[Server] in on_prem
firewall:R -- L:server
service db1(database)[db1] in on_prem
service db2(database)[db2] in on_prem
service db3(database)[db3] in on_prem
service db4(database)[db4] in on_prem
service db5(database)[db5] in on_prem
service db6(database)[db6] in on_prem
junction mid in on_prem
server:B -- T:mid
junction 1Leftofmid in on_prem
1Leftofmid:R -- L:mid
1Leftofmid:B -- T:db1
junction 2Leftofmid in on_prem
2Leftofmid:R -- L:1Leftofmid
2Leftofmid:B -- T:db2
junction 3Leftofmid in on_prem
3Leftofmid:R -- L:2Leftofmid
3Leftofmid:B -- T:db3
junction 1RightOfMid in on_prem
mid:R -- L:1RightOfMid
1RightOfMid:B -- T:db4
junction 2RightOfMid in on_prem
1RightOfMid:R -- L:2RightOfMid
2RightOfMid:B -- T:db5
junction 3RightOfMid in on_prem
2RightOfMid:R -- L:3RightOfMid
3RightOfMid:B -- T:db6
edge:R -- L:firewall
`
);
});
});
describe('architecture - external', () => {
// Skipped as the layout is not deterministic, and causes issues in E2E tests.
describe.skip('architecture - external', () => {
it('should allow adding external icons', () => {
urlSnapshotTest('http://localhost:9000/architecture-external.html');
});

View File

@@ -14,7 +14,7 @@ describe('Block diagram', () => {
);
});
it('BL2: should handle colums statement in sub-blocks', () => {
it('BL2: should handle columns statement in sub-blocks', () => {
imgSnapshotTest(
`block-beta
id1["Hello"]
@@ -30,7 +30,7 @@ describe('Block diagram', () => {
);
});
it('BL3: should align block widths and handle colums statement in sub-blocks', () => {
it('BL3: should align block widths and handle columns statement in sub-blocks', () => {
imgSnapshotTest(
`block-beta
block
@@ -46,7 +46,7 @@ describe('Block diagram', () => {
);
});
it('BL4: should align block widths and handle colums statements in deeper sub-blocks then 1 level', () => {
it('BL4: should align block widths and handle columns statements in deeper sub-blocks then 1 level', () => {
imgSnapshotTest(
`block-beta
columns 1
@@ -66,7 +66,7 @@ describe('Block diagram', () => {
);
});
it('BL5: should align block widths and handle colums statements in deeper sub-blocks then 1 level (alt)', () => {
it('BL5: should align block widths and handle columns statements in deeper sub-blocks then 1 level (alt)', () => {
imgSnapshotTest(
`block-beta
columns 1
@@ -236,7 +236,7 @@ describe('Block diagram', () => {
);
});
it('BL17: width alignment - blocks shold be equal in width', () => {
it('BL17: width alignment - blocks should be equal in width', () => {
imgSnapshotTest(
`block-beta
A("This is the text")

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -429,7 +429,7 @@ describe('Class diagram', () => {
classDiagram
class \`This\nTitle\nHas\nMany\nNewlines\` {
+String Also
-Stirng Many
-String Many
#int Members
+And()
-Many()
@@ -443,7 +443,7 @@ describe('Class diagram', () => {
classDiagram
class \`This\nTitle\nHas\nMany\nNewlines\` {
+String Also
-Stirng Many
-String Many
#int Members
+And()
-Many()
@@ -459,7 +459,7 @@ describe('Class diagram', () => {
namespace testingNamespace {
class \`This\nTitle\nHas\nMany\nNewlines\` {
+String Also
-Stirng Many
-String Many
#int Members
+And()
-Many()

View File

@@ -0,0 +1,652 @@
import { imgSnapshotTest, renderGraph } from '../../helpers/util.ts';
const testOptions = [
{ description: '', options: { logLevel: 1 } },
{ description: 'ELK: ', options: { logLevel: 1, layout: 'elk' } },
{ description: 'HD: ', options: { logLevel: 1, look: 'handDrawn' } },
];
describe('Entity Relationship Diagram Unified', () => {
testOptions.forEach(({ description, options }) => {
it(`${description}should render a simple ER diagram`, () => {
imgSnapshotTest(
`
erDiagram
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
`,
options
);
});
it(`${description}should render a simple ER diagram without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render an ER diagram with a recursive relationship`, () => {
imgSnapshotTest(
`
erDiagram
CUSTOMER ||..o{ CUSTOMER : refers
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
`,
options
);
});
it(`${description}should render an ER diagram with multiple relationships between the same two entities`, () => {
imgSnapshotTest(
`
erDiagram
CUSTOMER ||--|{ ADDRESS : "invoiced at"
CUSTOMER ||--|{ ADDRESS : "receives goods at"
`,
options
);
});
it(`${description}should render a cyclical ER diagram`, () => {
imgSnapshotTest(
`
erDiagram
A ||--|{ B : likes
B ||--|{ C : likes
C ||--|{ A : likes
`,
options
);
});
it(`${description}should render a not-so-simple ER diagram`, () => {
imgSnapshotTest(
`
erDiagram
CUSTOMER }|..|{ DELIVERY-ADDRESS : has
CUSTOMER ||--o{ ORDER : places
CUSTOMER ||--o{ INVOICE : "liable for"
DELIVERY-ADDRESS ||--o{ ORDER : receives
INVOICE ||--|{ ORDER : covers
ORDER ||--|{ ORDER-ITEM : includes
PRODUCT-CATEGORY ||--|{ PRODUCT : contains
PRODUCT ||--o{ ORDER-ITEM : "ordered in"
`,
options
);
});
it(`${description}should render a not-so-simple ER diagram without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
CUSTOMER }|..|{ DELIVERY-ADDRESS : has
CUSTOMER ||--o{ ORDER : places
CUSTOMER ||--o{ INVOICE : "liable for"
DELIVERY-ADDRESS ||--o{ ORDER : receives
INVOICE ||--|{ ORDER : covers
ORDER ||--|{ ORDER-ITEM : includes
PRODUCT-CATEGORY ||--|{ PRODUCT : contains
PRODUCT ||--o{ ORDER-ITEM : "ordered in"
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render multiple ER diagrams`, () => {
imgSnapshotTest(
[
`
erDiagram
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
`,
`
erDiagram
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
`,
],
options
);
});
it(`${description}should render an ER diagram with blank or empty labels`, () => {
imgSnapshotTest(
`
erDiagram
BOOK }|..|{ AUTHOR : ""
BOOK }|..|{ GENRE : " "
AUTHOR }|..|{ GENRE : " "
`,
options
);
});
it(`${description}should render entities that have no relationships`, () => {
renderGraph(
`
erDiagram
DEAD_PARROT
HERMIT
RECLUSE
SOCIALITE }o--o{ SOCIALITE : "interacts with"
RECLUSE }o--o{ SOCIALITE : avoids
`,
options
);
});
it(`${description}should render entities with and without attributes`, () => {
renderGraph(
`
erDiagram
BOOK { string title }
AUTHOR }|..|{ BOOK : writes
BOOK { float price }
`,
options
);
});
it(`${description}should render entities with generic and array attributes`, () => {
renderGraph(
`
erDiagram
BOOK {
string title
string[] authors
type~T~ type
}
`,
options
);
});
it(`${description}should render entities with generic and array attributes without htmlLabels`, () => {
renderGraph(
`
erDiagram
BOOK {
string title
string[] authors
type~T~ type
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with length in attributes type`, () => {
renderGraph(
`
erDiagram
CLUSTER {
varchar(99) name
string(255) description
}
`,
options
);
});
it(`${description}should render entities with length in attributes type without htmlLabels`, () => {
renderGraph(
`
erDiagram
CLUSTER {
varchar(99) name
string(255) description
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities and attributes with big and small entity names`, () => {
renderGraph(
`
erDiagram
PRIVATE_FINANCIAL_INSTITUTION {
string name
int turnover
}
PRIVATE_FINANCIAL_INSTITUTION ||..|{ EMPLOYEE : employs
EMPLOYEE { bool officer_of_firm }
`,
options
);
});
it(`${description}should render entities and attributes with big and small entity names without htmlLabels`, () => {
renderGraph(
`
erDiagram
PRIVATE_FINANCIAL_INSTITUTION {
string name
int turnover
}
PRIVATE_FINANCIAL_INSTITUTION ||..|{ EMPLOYEE : employs
EMPLOYEE { bool officer_of_firm }
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with attributes that begin with asterisk`, () => {
imgSnapshotTest(
`
erDiagram
BOOK {
int *id
string name
varchar(99) summary
}
BOOK }o..o{ STORE : soldBy
STORE {
int *id
string name
varchar(50) address
}
`,
options
);
});
it(`${description}should render entities with attributes that begin with asterisk without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
BOOK {
int *id
string name
varchar(99) summary
}
BOOK }o..o{ STORE : soldBy
STORE {
int *id
string name
varchar(50) address
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with keys`, () => {
renderGraph(
`
erDiagram
AUTHOR_WITH_LONG_ENTITY_NAME {
string name PK
}
AUTHOR_WITH_LONG_ENTITY_NAME }|..|{ BOOK : writes
BOOK {
float price
string author FK
string title PK
}
`,
options
);
});
it(`${description}should render entities with keys without htmlLabels`, () => {
renderGraph(
`
erDiagram
AUTHOR_WITH_LONG_ENTITY_NAME {
string name PK
}
AUTHOR_WITH_LONG_ENTITY_NAME }|..|{ BOOK : writes
BOOK {
float price
string author FK
string title PK
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with comments`, () => {
renderGraph(
`
erDiagram
AUTHOR_WITH_LONG_ENTITY_NAME {
string name "comment"
}
AUTHOR_WITH_LONG_ENTITY_NAME }|..|{ BOOK : writes
BOOK {
string author
string title "author comment"
float price "price comment"
}
`,
options
);
});
it(`${description}should render entities with comments without htmlLabels`, () => {
renderGraph(
`
erDiagram
AUTHOR_WITH_LONG_ENTITY_NAME {
string name "comment"
}
AUTHOR_WITH_LONG_ENTITY_NAME }|..|{ BOOK : writes
BOOK {
string author
string title "author comment"
float price "price comment"
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with keys and comments`, () => {
renderGraph(
`
erDiagram
AUTHOR_WITH_LONG_ENTITY_NAME {
string name PK "comment"
}
AUTHOR_WITH_LONG_ENTITY_NAME }|..|{ BOOK : writes
BOOK {
string description
float price "price comment"
string title PK "title comment"
string author FK
}
`,
options
);
});
it(`${description}should render entities with keys and comments without htmlLabels`, () => {
renderGraph(
`
erDiagram
AUTHOR_WITH_LONG_ENTITY_NAME {
string name PK "comment"
}
AUTHOR_WITH_LONG_ENTITY_NAME }|..|{ BOOK : writes
BOOK {
string description
float price "price comment"
string title PK "title comment"
string author FK
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with aliases`, () => {
renderGraph(
`
erDiagram
T1 one or zero to one or more T2 : test
T2 one or many optionally to zero or one T3 : test
T3 zero or more to zero or many T4 : test
T4 many(0) to many(1) T5 : test
T5 many optionally to one T6 : test
T6 only one optionally to only one T1 : test
T4 0+ to 1+ T6 : test
T1 1 to 1 T3 : test
`,
options
);
});
it(`${description}should render a simple ER diagram with a title`, () => {
imgSnapshotTest(
`---
title: simple ER diagram
---
erDiagram
CUSTOMER ||--o{ ORDER : places
ORDER ||--|{ LINE-ITEM : contains
`,
options
);
});
it(`${description}should render entities with entity name aliases`, () => {
imgSnapshotTest(
`
erDiagram
p[Person] {
varchar(64) firstName
varchar(64) lastName
}
c["Customer Account"] {
varchar(128) email
}
p ||--o| c : has
`,
options
);
});
it(`${description}should render relationship labels with line breaks`, () => {
imgSnapshotTest(
`
erDiagram
p[Person] {
string firstName
string lastName
}
a["Customer Account"] {
string email
}
b["Customer Account Secondary"] {
string email
}
c["Customer Account Tertiary"] {
string email
}
d["Customer Account Nth"] {
string email
}
p ||--o| a : "has<br />one"
p ||--o| b : "has<br />one<br />two"
p ||--o| c : "has<br />one<br/>two<br />three"
p ||--o| d : "has<br />one<br />two<br/>three<br />...<br/>Nth"
`,
options
);
});
it(`${description}should render an ER diagram with unicode text`, () => {
imgSnapshotTest(
`
erDiagram
_**testẽζØ😀㌕ぼ**_ {
*__List~List~int~~sdfds__* **driversLicense** PK "***The l😀icense #***"
*string(99)~T~~~~~~* firstName "Only __99__ <br>characters are a<br>llowed dsfsdfsdfsdfs"
string last*Name*
string __phone__ UK
int _age_
}
`,
options
);
});
it(`${description}should render an ER diagram with unicode text without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
_**testẽζØ😀㌕ぼ**_ {
*__List~List~int~~sdfds__* **driversLicense** PK "***The l😀icense #***"
*string(99)~T~~~~~~* firstName "Only __99__ <br>characters are a<br>llowed dsfsdfsdfsdfs"
string last*Name*
string __phone__ UK
int _age_
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render an ER diagram with relationships with unicode text`, () => {
imgSnapshotTest(
`
erDiagram
person[😀] {
string *first*Name
string _**last**Name_
}
a["*Customer Account*"] {
**string** ema*i*l
}
person ||--o| a : __hẽ😀__
`,
options
);
});
it(`${description}should render an ER diagram with relationships with unicode text without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
person[😀] {
string *first*Name
string _**last**Name_
}
a["*Customer Account*"] {
**string** ema*i*l
}
person ||--o| a : __hẽ😀__
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render an ER diagram with TB direction`, () => {
imgSnapshotTest(
`
erDiagram
direction TB
CAR ||--|{ NAMED-DRIVER : allows
PERSON ||..o{ NAMED-DRIVER : is
`,
options
);
});
it(`${description}should render an ER diagram with BT direction`, () => {
imgSnapshotTest(
`
erDiagram
direction BT
CAR ||--|{ NAMED-DRIVER : allows
PERSON ||..o{ NAMED-DRIVER : is
`,
options
);
});
it(`${description}should render an ER diagram with LR direction`, () => {
imgSnapshotTest(
`
erDiagram
direction LR
CAR ||--|{ NAMED-DRIVER : allows
PERSON ||..o{ NAMED-DRIVER : is
`,
options
);
});
it(`${description}should render an ER diagram with RL direction`, () => {
imgSnapshotTest(
`
erDiagram
direction RL
CAR ||--|{ NAMED-DRIVER : allows
PERSON ||..o{ NAMED-DRIVER : is
`,
options
);
});
it(`${description}should render entities with styles applied from style statement`, () => {
imgSnapshotTest(
`
erDiagram
c[CUSTOMER]
p[PERSON]
style c,p fill:#f9f,stroke:blue, color:grey, font-size:24px,font-weight:bold
`,
options
);
});
it(`${description}should render entities with styles applied from style statement without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
c[CUSTOMER]
p[PERSON]
style c,p fill:#f9f,stroke:blue, color:grey, font-size:24px,font-weight:bold
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with styles applied from class statement`, () => {
imgSnapshotTest(
`
erDiagram
c[CUSTOMER]
p[PERSON]:::blue
classDef bold font-size:24px, font-weight: bold
classDef blue stroke:lightblue, color: #0000FF
class c,p bold
`,
options
);
});
it(`${description}should render entities with styles applied from class statement without htmlLabels`, () => {
imgSnapshotTest(
`
erDiagram
c[CUSTOMER]
p[PERSON]:::blue
classDef bold font-size:24px, font-weight: bold
classDef blue stroke:lightblue, color: #0000FF
class c,p bold
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render entities with styles applied from the default class and other styles`, () => {
imgSnapshotTest(
`
erDiagram
c[CUSTOMER]
p[PERSON]:::blue
classDef blue stroke:lightblue, color: #0000FF
classDef default fill:pink
style c color:green
`,
{ ...options }
);
});
});
});

View File

@@ -109,8 +109,8 @@ describe('Entity Relationship Diagram', () => {
const style = svg.attr('style');
expect(style).to.match(/^max-width: [\d.]+px;$/);
const maxWidthValue = parseFloat(style.match(/[\d.]+/g).join(''));
// use within because the absolute value can be slightly different depending on the environment ±5%
expect(maxWidthValue).to.be.within(140 * 0.95, 140 * 1.05);
// use within because the absolute value can be slightly different depending on the environment ±6%
expect(maxWidthValue).to.be.within(140 * 0.96, 140 * 1.06);
});
});
@@ -125,8 +125,8 @@ describe('Entity Relationship Diagram', () => {
);
cy.get('svg').should((svg) => {
const width = parseFloat(svg.attr('width'));
// use within because the absolute value can be slightly different depending on the environment ±5%
expect(width).to.be.within(140 * 0.95, 140 * 1.05);
// use within because the absolute value can be slightly different depending on the environment ±6%
expect(width).to.be.within(140 * 0.96, 140 * 1.06);
// expect(svg).to.have.attr('height', '465');
expect(svg).to.not.have.attr('style');
});

View File

@@ -1,6 +1,6 @@
import { imgSnapshotTest, renderGraph } from '../../helpers/util.ts';
import { imgSnapshotTest, renderGraph, verifyNumber } from '../../helpers/util.ts';
describe.skip('Flowchart ELK', () => {
describe('Flowchart ELK', () => {
it('1-elk: should render a simple flowchart', () => {
imgSnapshotTest(
`flowchart-elk TD
@@ -109,7 +109,7 @@ describe.skip('Flowchart ELK', () => {
const style = svg.attr('style');
expect(style).to.match(/^max-width: [\d.]+px;$/);
const maxWidthValue = parseFloat(style.match(/[\d.]+/g).join(''));
expect(maxWidthValue).to.be.within(230 * 0.95, 230 * 1.05);
verifyNumber(maxWidthValue, 380);
});
});
it('8-elk: should render a flowchart when useMaxWidth is false', () => {
@@ -128,7 +128,7 @@ describe.skip('Flowchart ELK', () => {
const width = parseFloat(svg.attr('width'));
// use within because the absolute value can be slightly different depending on the environment ±5%
// expect(height).to.be.within(446 * 0.95, 446 * 1.05);
expect(width).to.be.within(230 * 0.95, 230 * 1.05);
verifyNumber(width, 380);
expect(svg).to.not.have.attr('style');
});
});
@@ -208,13 +208,13 @@ describe.skip('Flowchart ELK', () => {
`flowchart-elk TB
internet
nat
routeur
router
lb1
lb2
compute1
compute2
subgraph project
routeur
router
nat
subgraph subnet1
compute1
@@ -225,8 +225,8 @@ describe.skip('Flowchart ELK', () => {
lb2
end
end
internet --> routeur
routeur --> subnet1 & subnet2
internet --> router
router --> subnet1 & subnet2
subnet1 & subnet2 --> nat --> internet
`,
{ htmlLabels: true, flowchart: { htmlLabels: true }, securityLevel: 'loose' }
@@ -443,7 +443,7 @@ flowchart-elk TD
{ htmlLabels: true, flowchart: { htmlLabels: true }, securityLevel: 'loose' }
);
});
it('63-elk: title on subgraphs should be themable', () => {
it('63-elk: title on subgraphs should be themeable', () => {
imgSnapshotTest(
`
%%{init:{"theme":"base", "themeVariables": {"primaryColor":"#411d4e", "titleColor":"white", "darkMode":true}}}%%
@@ -692,7 +692,7 @@ A --> B
{}
);
cy.get('svg').should((svg) => {
const edges = svg.querySelectorAll('.edges > path');
const edges = svg[0].querySelectorAll('.edges > path');
edges.forEach((edge) => {
expect(edge).to.have.class('flowchart-link');
});
@@ -739,7 +739,7 @@ NL\`") --"\`1o **bold**\`"--> c
{ flowchart: { titleTopMargin: 0 } }
);
});
it('Wrapping long text with a new line', () => {
it.skip('Wrapping long text with a new line', () => {
imgSnapshotTest(
`%%{init: {"flowchart": {"htmlLabels": true}} }%%
flowchart-elk LR
@@ -841,7 +841,7 @@ end
{ flowchart: { titleTopMargin: 0 } }
);
});
it('Sub graphs and markdown strings', () => {
it('Sub graphs', () => {
imgSnapshotTest(
`---
config:
@@ -857,6 +857,196 @@ flowchart LR
D --> E
A["A"]
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6080: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
subgraph s1["Untitled subgraph"]
n1["Evaluate"]
n2["Option 1"]
n3["Option 2"]
n4["fa:fa-car Option 3"]
end
subgraph s2["Untitled subgraph"]
n5["Evaluate"]
n6["Option 1"]
n7["Option 2"]
n8["fa:fa-car Option 3"]
end
A["Start"] -- Some text --> B("Continue")
B --> C{"Evaluate"}
C -- One --> D["Option 1"]
C -- Two --> E["Option 2"]
C -- Three --> F["fa:fa-car Option 3"]
n1 -- One --> n2
n1 -- Two --> n3
n1 -- Three --> n4
n5 -- One --> n6
n5 -- Two --> n7
n5 -- Three --> n8
n1@{ shape: diam}
n2@{ shape: rect}
n3@{ shape: rect}
n4@{ shape: rect}
n5@{ shape: diam}
n6@{ shape: rect}
n7@{ shape: rect}
n8@{ shape: rect}
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6088-1: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
subgraph S2
subgraph s1["APA"]
D{"Use the editor"}
end
D -- Mermaid js --> I{"fa:fa-code Text"}
D --> I
D --> I
end
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6088-2: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
a
subgraph s0["APA"]
subgraph s8["APA"]
subgraph s1["APA"]
D{"X"}
E[Q]
end
subgraph s3["BAPA"]
F[Q]
I
end
D --> I
D --> I
D --> I
I{"X"}
end
end
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6088-3: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
a
D{"Use the editor"}
D -- Mermaid js --> I{"fa:fa-code Text"}
D-->I
D-->I
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6088-4: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
subgraph s1["Untitled subgraph"]
n1["Evaluate"]
n2["Option 1"]
n3["Option 2"]
n4["fa:fa-car Option 3"]
end
subgraph s2["Untitled subgraph"]
n5["Evaluate"]
n6["Option 1"]
n7["Option 2"]
n8["fa:fa-car Option 3"]
end
A["Start"] -- Some text --> B("Continue")
B --> C{"Evaluate"}
C -- One --> D["Option 1"]
C -- Two --> E["Option 2"]
C -- Three --> F["fa:fa-car Option 3"]
n1 -- One --> n2
n1 -- Two --> n3
n1 -- Three --> n4
n5 -- One --> n6
n5 -- Two --> n7
n5 -- Three --> n8
n1@{ shape: diam}
n2@{ shape: rect}
n3@{ shape: rect}
n4@{ shape: rect}
n5@{ shape: diam}
n6@{ shape: rect}
n7@{ shape: rect}
n8@{ shape: rect}
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6088-5: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
A{A} --> B & C
`,
{ flowchart: { titleTopMargin: 0 } }
);
});
it('6088-6: should handle diamond shape intersections', () => {
imgSnapshotTest(
`---
config:
layout: elk
---
flowchart LR
A{A} --> B & C
subgraph "subbe"
A
end
`,
{ flowchart: { titleTopMargin: 0 } }
);

View File

@@ -12,7 +12,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -30,7 +29,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: true },
fontFamily: 'courier',
}
@@ -47,7 +45,7 @@ describe('Flowchart HandDrawn', () => {
C -->|Two| E[iPhone]
C -->|Three| F[Car]
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -62,7 +60,7 @@ describe('Flowchart HandDrawn', () => {
C -->|Two| E[\\iPhone\\]
C -->|Three| F[Car]
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -78,7 +76,7 @@ describe('Flowchart HandDrawn', () => {
classDef processHead fill:#888888,color:white,font-weight:bold,stroke-width:3px,stroke:#001f3f
class 1A,1B,D,E processHead
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -107,7 +105,7 @@ describe('Flowchart HandDrawn', () => {
35(SAM.CommonFA.PopulationFME)-->39(SAM.CommonFA.ChargeDetails)
36(SAM.CommonFA.PremetricCost)-->39(SAM.CommonFA.ChargeDetails)
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -178,7 +176,7 @@ describe('Flowchart HandDrawn', () => {
9a072290_1ec3_e711_8c5a_005056ad0002-->d6072290_1ec3_e711_8c5a_005056ad0002
9a072290_1ec3_e711_8c5a_005056ad0002-->71082290_1ec3_e711_8c5a_005056ad0002
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -187,7 +185,7 @@ describe('Flowchart HandDrawn', () => {
`
graph TB;subgraph "number as labels";1;end;
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -199,7 +197,7 @@ describe('Flowchart HandDrawn', () => {
a1-->a2
end
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -211,7 +209,7 @@ describe('Flowchart HandDrawn', () => {
a1-->a2
end
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -246,7 +244,7 @@ describe('Flowchart HandDrawn', () => {
style foo fill:#F99,stroke-width:2px,stroke:#F0F,color:darkred
style bar fill:#999,stroke-width:10px,stroke:#0F0,color:blue
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -348,7 +346,7 @@ describe('Flowchart HandDrawn', () => {
sid-7CE72B24-E0C1-46D3-8132-8BA66BE05AA7-->sid-4DA958A0-26D9-4D47-93A7-70F39FD7D51A;
sid-7CE72B24-E0C1-46D3-8132-8BA66BE05AA7-->sid-4FC27B48-A6F9-460A-A675-021F5854FE22;
`,
{ look: 'handDrawn', handDrawnSeed: 1, fontFamily: 'courier' }
{ look: 'handDrawn', fontFamily: 'courier' }
);
});
@@ -364,7 +362,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
listUrl: false,
listId: 'color styling',
fontFamily: 'courier',
@@ -390,7 +387,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
listUrl: false,
listId: 'color styling',
fontFamily: 'courier',
@@ -411,7 +407,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -435,7 +430,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -457,7 +451,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -471,7 +464,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -485,7 +477,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -500,7 +491,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -527,7 +517,6 @@ describe('Flowchart HandDrawn', () => {
class A someclass;`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -544,7 +533,7 @@ describe('Flowchart HandDrawn', () => {
C -->|Two| E[iPhone]
C -->|Three| F[fa:fa-car Car]
`,
{ look: 'handDrawn', handDrawnSeed: 1, flowchart: { nodeSpacing: 50 }, fontFamily: 'courier' }
{ look: 'handDrawn', flowchart: { nodeSpacing: 50 }, fontFamily: 'courier' }
);
});
@@ -560,7 +549,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { rankSpacing: '100' },
fontFamily: 'courier',
}
@@ -578,7 +566,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -603,7 +590,7 @@ describe('Flowchart HandDrawn', () => {
click E "notes://do-your-thing/id" "other protocol test"
click F "javascript:alert('test')" "script test"
`,
{ look: 'handDrawn', handDrawnSeed: 1, securityLevel: 'loose', fontFamily: 'courier' }
{ look: 'handDrawn', securityLevel: 'loose', fontFamily: 'courier' }
);
});
@@ -623,7 +610,7 @@ describe('Flowchart HandDrawn', () => {
click B "index.html#link-clicked" "link test"
click D testClick "click test"
`,
{ look: 'handDrawn', handDrawnSeed: 1, flowchart: { htmlLabels: true } }
{ look: 'handDrawn', flowchart: { htmlLabels: true } }
);
});
@@ -645,7 +632,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -664,7 +650,7 @@ describe('Flowchart HandDrawn', () => {
class A myClass1
class D myClass2
`,
{ look: 'handDrawn', handDrawnSeed: 1, flowchart: { htmlLabels: true } }
{ look: 'handDrawn', flowchart: { htmlLabels: true } }
);
});
@@ -682,7 +668,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -711,7 +696,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -728,7 +712,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -752,7 +735,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: false },
fontFamily: 'courier',
}
@@ -769,7 +751,7 @@ describe('Flowchart HandDrawn', () => {
C -->|Two| E[iPhone]
C -->|Three| F[fa:fa-car Car]
`,
{ look: 'handDrawn', handDrawnSeed: 1, flowchart: { diagramPadding: 0 } }
{ look: 'handDrawn', flowchart: { diagramPadding: 0 } }
);
});
@@ -804,7 +786,7 @@ describe('Flowchart HandDrawn', () => {
`graph TD
a["<strong>Haiya</strong>"]-->b
`,
{ look: 'handDrawn', handDrawnSeed: 1, htmlLabels: false, flowchart: { htmlLabels: false } }
{ look: 'handDrawn', htmlLabels: false, flowchart: { htmlLabels: false } }
);
});
it('FDH37: should render non-escaped with html labels', () => {
@@ -814,7 +796,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -830,7 +811,7 @@ describe('Flowchart HandDrawn', () => {
C -->|Two| E[iPhone]
C -->|Three| F[fa:fa-car Car]
`,
{ look: 'handDrawn', handDrawnSeed: 1, flowchart: { useMaxWidth: true } }
{ look: 'handDrawn', flowchart: { useMaxWidth: true } }
);
cy.get('svg').should((svg) => {
expect(svg).to.have.attr('width', '100%');
@@ -853,7 +834,7 @@ describe('Flowchart HandDrawn', () => {
C -->|Two| E[iPhone]
C -->|Three| F[fa:fa-car Car]
`,
{ look: 'handDrawn', handDrawnSeed: 1, flowchart: { useMaxWidth: false } }
{ look: 'handDrawn', flowchart: { useMaxWidth: false } }
);
cy.get('svg').should((svg) => {
// const height = parseFloat(svg.attr('height'));
@@ -874,7 +855,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -904,7 +884,6 @@ describe('Flowchart HandDrawn', () => {
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -919,7 +898,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -937,7 +915,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -977,7 +954,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -999,7 +975,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -1016,7 +991,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -1032,7 +1006,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
htmlLabels: true,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
@@ -1051,7 +1024,6 @@ graph TD
`,
{
look: 'handDrawn',
handDrawnSeed: 1,
flowchart: { htmlLabels: true },
securityLevel: 'loose',
}

View File

@@ -0,0 +1,28 @@
import { imgSnapshotTest } from '../../helpers/util.ts';
const themes = ['default', 'forest', 'dark', 'base', 'neutral'];
describe('when rendering flowchart with icons', () => {
for (const theme of themes) {
it(`should render icons from fontawesome library on theme ${theme}`, () => {
imgSnapshotTest(
`flowchart TD
A("fab:fa-twitter Twitter") --> B("fab:fa-facebook Facebook")
B --> C("fa:fa-coffee Coffee")
C --> D("fa:fa-car Car")
D --> E("fab:fa-github GitHub")
`,
{ theme }
);
});
it(`should render registered icons on theme ${theme}`, () => {
imgSnapshotTest(
`flowchart TD
A("fa:fa-bell Bell")
`,
{ theme }
);
});
}
});

View File

@@ -99,7 +99,7 @@ describe('Flowchart v2', () => {
const style = svg.attr('style');
expect(style).to.match(/^max-width: [\d.]+px;$/);
const maxWidthValue = parseFloat(style.match(/[\d.]+/g).join(''));
expect(maxWidthValue).to.be.within(417 * 0.95, 417 * 1.05);
expect(maxWidthValue).to.be.within(440 * 0.95, 440 * 1.05);
});
});
it('8: should render a flowchart when useMaxWidth is false', () => {
@@ -118,7 +118,7 @@ describe('Flowchart v2', () => {
const width = parseFloat(svg.attr('width'));
// use within because the absolute value can be slightly different depending on the environment ±5%
// expect(height).to.be.within(446 * 0.95, 446 * 1.05);
expect(width).to.be.within(417 * 0.95, 417 * 1.05);
expect(width).to.be.within(440 * 0.95, 440 * 1.05);
expect(svg).to.not.have.attr('style');
});
});
@@ -198,13 +198,13 @@ describe('Flowchart v2', () => {
`flowchart TB
internet
nat
routeur
router
lb1
lb2
compute1
compute2
subgraph project
routeur
router
nat
subgraph subnet1
compute1
@@ -215,8 +215,8 @@ describe('Flowchart v2', () => {
lb2
end
end
internet --> routeur
routeur --> subnet1 & subnet2
internet --> router
router --> subnet1 & subnet2
subnet1 & subnet2 --> nat --> internet
`,
{ htmlLabels: true, flowchart: { htmlLabels: true }, securityLevel: 'loose' }
@@ -433,7 +433,7 @@ flowchart TD
{ htmlLabels: true, flowchart: { htmlLabels: true }, securityLevel: 'loose' }
);
});
it('63: title on subgraphs should be themable', () => {
it('63: title on subgraphs should be themeable', () => {
imgSnapshotTest(
`
%%{init:{"theme":"base", "themeVariables": {"primaryColor":"#411d4e", "titleColor":"white", "darkMode":true}}}%%
@@ -699,7 +699,7 @@ A --> B
{ flowchart: { titleTopMargin: 10 } }
);
});
it('3192: It should be possieble to render flowcharts with invisible edges', () => {
it('3192: It should be possible to render flowcharts with invisible edges', () => {
imgSnapshotTest(
`---
title: Simple flowchart with invisible edges
@@ -1076,4 +1076,41 @@ end
);
});
});
describe('New @ syntax for node metadata edge cases', () => {
it('should be possible to use @ syntax to add labels on multi nodes', () => {
imgSnapshotTest(
`flowchart TB
n2["label for n2"] & n4@{ label: "label for n4"} & n5@{ label: "label for n5"}
`,
{}
);
});
it('should be possible to use @ syntax to add labels with trail spaces and &', () => {
imgSnapshotTest(
`flowchart TB
n2["label for n2"] & n4@{ label: "label for n4"} & n5@{ label: "label for n5"}
`,
{}
);
});
it('should be possible to use @ syntax to add labels with trail spaces', () => {
imgSnapshotTest(
`flowchart TB
n2["label for n2"]
n4@{ label: "label for n4"}
n5@{ label: "label for n5"}
`,
{}
);
});
it('should be possible to use @ syntax to add labels with trail spaces and edge/link', () => {
imgSnapshotTest(
`flowchart TD
A["A"] --> B["for B"] & C@{ label: "for c"} & E@{label : "for E"}
D@{label: "for D"}
`,
{}
);
});
});
});

View File

@@ -895,7 +895,7 @@ graph TD
imgSnapshotTest(
`
graph TD
classDef default fill:#a34,stroke:#000,stroke-width:4px,color:#fff
classDef default fill:#a34,stroke:#000,stroke-width:4px,color:#fff
hello --> default
`,
{ htmlLabels: true, flowchart: { htmlLabels: true }, securityLevel: 'loose' }
@@ -917,4 +917,60 @@ graph TD
}
);
});
it('#6369: edge color should affect arrow head', () => {
imgSnapshotTest(
`
flowchart LR
A --> B
A --> C
C --> D
linkStyle 0 stroke:#D50000
linkStyle 2 stroke:#D50000
`,
{
flowchart: { htmlLabels: true },
securityLevel: 'loose',
}
);
});
it('68: should honor subgraph direction when inheritDir is false', () => {
imgSnapshotTest(
`
%%{init: {"flowchart": { "inheritDir": false }}}%%
flowchart TB
direction LR
subgraph A
direction TB
a --> b
end
subgraph B
c --> d
end
`,
{
fontFamily: 'courier',
}
);
});
it('69: should inherit global direction when inheritDir is true', () => {
imgSnapshotTest(
`
%%{init: {"flowchart": { "inheritDir": true }}}%%
flowchart TB
direction LR
subgraph A
direction TB
a --> b
end
subgraph B
c --> d
end
`,
{
fontFamily: 'courier',
}
);
});
});

View File

@@ -117,7 +117,7 @@ describe('Gantt diagram', () => {
{}
);
});
it('should FAIL redering a gantt chart for issue #1060 with invalid date', () => {
it('should FAIL rendering a gantt chart for issue #1060 with invalid date', () => {
imgSnapshotTest(
`
gantt
@@ -358,6 +358,23 @@ describe('Gantt diagram', () => {
);
});
it('should render a gantt diagram with a vert tag', () => {
imgSnapshotTest(
`
gantt
title A Gantt Diagram
dateFormat ss
axisFormat %Ss
section Section
A task : a1, 00, 6s
Milestone : vert, 01,
section Another
Task in sec : 06, 3s
another task : 3s
`
);
});
it('should render a gantt diagram with tick is 2 milliseconds', () => {
imgSnapshotTest(
`
@@ -573,7 +590,7 @@ describe('Gantt diagram', () => {
`
);
});
it('should render a gantt diagram exculding friday and saturday', () => {
it('should render a gantt diagram excluding friday and saturday', () => {
imgSnapshotTest(
`gantt
title A Gantt Diagram
@@ -584,7 +601,7 @@ describe('Gantt diagram', () => {
A task :a1, 2024-02-28, 10d`
);
});
it('should render a gantt diagram exculding saturday and sunday', () => {
it('should render a gantt diagram excluding saturday and sunday', () => {
imgSnapshotTest(
`gantt
title A Gantt Diagram
@@ -671,7 +688,7 @@ describe('Gantt diagram', () => {
title Gantt Digram
dateFormat YYYY-MM-DD
section Section
;A task with a semiclon :a1, 2014-01-01, 30d
;A task with a semicolon :a1, 2014-01-01, 30d
Another task :after a1 , 20d
section Another
Task in sec :2014-01-12 , 12d

View File

@@ -11,7 +11,7 @@ describe('Git Graph diagram', () => {
{}
);
});
it('2: should render a simple gitgraph with commit on main branch with Id', () => {
it('2: should render a simple gitgraph with commit on main branch with id', () => {
imgSnapshotTest(
`gitGraph
commit id: "One"
@@ -253,7 +253,7 @@ describe('Git Graph diagram', () => {
`
gitGraph
checkout main
%% Make sure to manually set the ID of all commits, for consistent visual tests
%% Make sure to manually set the id of all commits, for consistent visual tests
commit id: "1-abcdefg"
checkout main
branch branch1
@@ -343,7 +343,7 @@ gitGraph
{}
);
});
it('16: should render a simple gitgraph with commit on main branch with Id | Vertical Branch', () => {
it('16: should render a simple gitgraph with commit on main branch with id | Vertical Branch', () => {
imgSnapshotTest(
`gitGraph TB:
commit id: "One"
@@ -585,7 +585,7 @@ gitGraph
`
gitGraph TB:
checkout main
%% Make sure to manually set the ID of all commits, for consistent visual tests
%% Make sure to manually set the id of all commits, for consistent visual tests
commit id: "1-abcdefg"
checkout main
branch branch1
@@ -1024,7 +1024,7 @@ gitGraph TB:
{}
);
});
it('51: should render a simple gitgraph with commit on main branch with Id | Vertical Branch - Bottom-to-top', () => {
it('51: should render a simple gitgraph with commit on main branch with id | Vertical Branch - Bottom-to-top', () => {
imgSnapshotTest(
`gitGraph BT:
commit id: "One"
@@ -1266,7 +1266,7 @@ gitGraph TB:
`
gitGraph BT:
checkout main
%% Make sure to manually set the ID of all commits, for consistent visual tests
%% Make sure to manually set the id of all commits, for consistent visual tests
commit id: "1-abcdefg"
checkout main
branch branch1
@@ -1491,7 +1491,7 @@ gitGraph TB:
`
gitGraph
switch main
%% Make sure to manually set the ID of all commits, for consistent visual tests
%% Make sure to manually set the id of all commits, for consistent visual tests
commit id: "1-abcdefg"
switch main
branch branch1

View File

@@ -124,3 +124,20 @@ describe('Test iconShape with different h', () => {
imgSnapshotTest(flowchartCode);
});
});
describe('Test colored iconShape', () => {
it('with no styles', () => {
let flowchartCode = `flowchart TB\n`;
const icon = 'fluent-emoji:tropical-fish';
flowchartCode += ` nA --> nAA@{ icon: '${icon}', form: 'square', label: 'icon with color' }\n`;
imgSnapshotTest(flowchartCode);
});
it('with styles', () => {
let flowchartCode = `flowchart TB\n`;
const icon = 'fluent-emoji:tropical-fish';
flowchartCode += ` nA --> nAA@{ icon: '${icon}', form: 'square', label: 'icon with color' }\n`;
flowchartCode += ` style nAA fill:#f9f,stroke:#333,stroke-width:4px \n`;
imgSnapshotTest(flowchartCode);
});
});

View File

@@ -63,4 +63,199 @@ section Checkout from website
{ journey: { useMaxWidth: false } }
);
});
it('should initialize with a left margin of 150px for user journeys', () => {
renderGraph(
`
---
config:
journey:
maxLabelWidth: 320
---
journey
title User Journey Example
section Onboarding
Sign Up: 5:
Browse Features: 3:
Use Core Functionality: 4:
section Engagement
Browse Features: 3
Use Core Functionality: 4
`,
{ journey: { useMaxWidth: true } }
);
let diagramStartX;
cy.contains('foreignobject', 'Sign Up').then(($diagram) => {
diagramStartX = parseFloat($diagram.attr('x'));
expect(diagramStartX).to.be.closeTo(150, 2);
});
});
it('should maintain sufficient space between legend and diagram when legend labels are longer', () => {
renderGraph(
`journey
title Web hook life cycle
section Darkoob
Make preBuilt:5: Darkoob user
register slug : 5: Darkoob userf deliberately increasing the size of this label to check if distance between legend and diagram is maintained
Map slug to a Prebuilt Job:5: Darkoob user
section External Service
set Darkoob slug as hook for an Event : 5 : admin Exjjjnjjjj qwerty
listen to the events : 5 : External Service
call darkoob endpoint : 5 : External Service
section Darkoob
check for inputs : 5 : DarkoobAPI
run the prebuilt job : 5 : DarkoobAPI
`,
{ journey: { useMaxWidth: true } }
);
let LabelEndX, diagramStartX;
// Get right edge of the legend
cy.contains('tspan', 'Darkoob userf').then((textBox) => {
const bbox = textBox[0].getBBox();
LabelEndX = bbox.x + bbox.width;
});
// Get left edge of the diagram
cy.contains('foreignobject', 'Make preBuilt').then((rect) => {
diagramStartX = parseFloat(rect.attr('x'));
});
// Assert right edge of the diagram is greater than or equal to the right edge of the label
cy.then(() => {
expect(diagramStartX).to.be.gte(LabelEndX);
});
});
it('should wrap a single long word with hyphenation', () => {
renderGraph(
`
---
config:
journey:
maxLabelWidth: 100
---
journey
title Long Word Test
section Test
VeryLongWord: 5: Supercalifragilisticexpialidocious
`,
{ journey: { useMaxWidth: true } }
);
// Verify that the line ends with a hyphen, indicating proper hyphenation for words exceeding maxLabelWidth.
cy.get('tspan').then((tspans) => {
const hasHyphen = [...tspans].some((t) => t.textContent.trim().endsWith('-'));
return expect(hasHyphen).to.be.true;
});
});
it('should wrap text on whitespace without adding hyphens', () => {
renderGraph(
`
---
config:
journey:
maxLabelWidth: 200
---
journey
title Whitespace Test
section Test
TextWithSpaces: 5: Gustavo Fring is played by Giancarlo Esposito and is a character in Breaking Bad.
`,
{ journey: { useMaxWidth: true } }
);
// Verify that none of the text spans end with a hyphen.
cy.get('tspan').each(($el) => {
const text = $el.text();
expect(text.trim()).not.to.match(/-$/);
});
});
it('should wrap long labels into multiple lines, keep them under max width, and maintain margins', () => {
renderGraph(
`
---
config:
journey:
maxLabelWidth: 320
---
journey
title User Journey Example
section Onboarding
Sign Up: 5: This is a long label that will be split into multiple lines to test the wrapping functionality
Browse Features: 3: This is another long label that will be split into multiple lines to test the wrapping functionality
Use Core Functionality: 4: This is yet another long label that will be split into multiple lines to test the wrapping functionality
section Engagement
Browse Features: 3
Use Core Functionality: 4
`,
{ journey: { useMaxWidth: true } }
);
let diagramStartX, maxLineWidth;
// Get the diagram's left edge x-coordinate
cy.contains('foreignobject', 'Sign Up')
.then(($diagram) => {
diagramStartX = parseFloat($diagram.attr('x'));
})
.then(() => {
cy.get('text.legend').then(($lines) => {
// Check that there are multiple lines
expect($lines.length).to.be.equal(9);
// Check that all lines are under the maxLabelWidth
$lines.each((index, el) => {
const bbox = el.getBBox();
expect(bbox.width).to.be.lte(320);
maxLineWidth = Math.max(maxLineWidth || 0, bbox.width);
});
/** The expected margin between the diagram and the legend is 150px, as defined by
* conf.leftMargin in user-journey-config.js
*/
expect(diagramStartX - maxLineWidth).to.be.closeTo(150, 2);
});
});
});
it('should correctly render the user journey diagram title with the specified styling', () => {
renderGraph(
`---
config:
journey:
titleColor: "#2900A5"
titleFontFamily: "Times New Roman"
titleFontSize: "5rem"
---
journey
title User Journey Example
section Onboarding
Sign Up: 5: John, Shahir
Complete Profile: 4: John
section Engagement
Browse Features: 3: John
Use Core Functionality: 4: John
section Retention
Revisit Application: 5: John
Invite Friends: 3: John
size: 2rem
`
);
cy.get('text').contains('User Journey Example').as('title');
cy.get('@title').then(($title) => {
expect($title).to.have.attr('fill', '#2900A5');
expect($title).to.have.attr('font-family', 'Times New Roman');
expect($title).to.have.attr('font-size', '5rem');
});
});
});

View File

@@ -0,0 +1,136 @@
import { imgSnapshotTest } from '../../helpers/util.ts';
describe('Kanban diagram', () => {
it('1: should render a kanban with a single section', () => {
imgSnapshotTest(
`kanban
id1[Todo]
docs[Create Documentation]
docs[Create Blog about the new diagram]
`,
{}
);
});
it('2: should render a kanban with multiple sections', () => {
imgSnapshotTest(
`kanban
id1[Todo]
docs[Create Documentation]
id2
docs[Create Blog about the new diagram]
`,
{}
);
});
it('3: should render a kanban with a single wrapping node', () => {
imgSnapshotTest(
`kanban
id1[Todo]
id2[Title of diagram is more than 100 chars when user duplicates diagram with 100 char, wrapping]
`,
{}
);
});
it('4: should handle the height of a section with a wrapping node at the end', () => {
imgSnapshotTest(
`kanban
id1[Todo]
id2[One line]
id3[Title of diagram is more than 100 chars when user duplicates diagram with 100 char, wrapping]
`,
{}
);
});
it('5: should handle the height of a section with a wrapping node at the top', () => {
imgSnapshotTest(
`kanban
id1[Todo]
id2[Title of diagram is more than 100 chars when user duplicates diagram with 100 char, wrapping]
id3[One line]
`,
{}
);
});
it('6: should handle the height of a section with a wrapping node in the middle', () => {
imgSnapshotTest(
`kanban
id1[Todo]
id2[One line]
id3[Title of diagram is more than 100 chars when user duplicates diagram with 100 char, wrapping]
id4[One line]
`,
{}
);
});
it('6: should handle assignments', () => {
imgSnapshotTest(
`kanban
id1[Todo]
docs[Create Documentation]
id2[In progress]
docs[Create Blog about the new diagram]@{ assigned: 'knsv' }
`,
{}
);
});
it('7: should handle prioritization', () => {
imgSnapshotTest(
`kanban
id2[In progress]
vh[Very High]@{ priority: 'Very High' }
h[High]@{ priority: 'High' }
m[Default priority]
l[Low]@{ priority: 'Low' }
vl[Very Low]@{ priority: 'Very Low' }
`,
{}
);
});
it('7: should handle external tickets', () => {
imgSnapshotTest(
`kanban
id1[Todo]
docs[Create Documentation]
id2[In progress]
docs[Create Blog about the new diagram]@{ ticket: MC-2037 }
`,
{}
);
});
it('8: should handle assignments, prioritization and tickets ids in the same item', () => {
imgSnapshotTest(
`kanban
id2[In progress]
docs[Create Blog about the new diagram]@{ priority: 'Very Low', ticket: MC-2037, assigned: 'knsv' }
`,
{}
);
});
it('10: Full example', () => {
imgSnapshotTest(
`---
config:
kanban:
ticketBaseUrl: 'https://abc123.atlassian.net/browse/#TICKET#'
---
kanban
id1[Todo]
docs[Create Documentation]
docs[Create Blog about the new diagram]
id7[In progress]
id6[Create renderer so that it works in all cases. We also add some extra text here for testing purposes. And some more just for the extra flare.]
id8[Design grammar]@{ assigned: 'knsv' }
id9[Ready for deploy]
id10[Ready for test]
id11[Done]
id5[define getData]
id2[Title of diagram is more than 100 chars when user duplicates diagram with 100 char]@{ ticket: MC-2036, priority: 'Very High'}
id3[Update DB function]@{ ticket: MC-2037, assigned: knsv, priority: 'High' }
id4[Create parsing tests]@{ ticket: MC-2038, assigned: 'K.Sveidqvist', priority: 'High' }
id66[last item]@{ priority: 'Very Low', assigned: 'knsv' }
id12[Can't reproduce]
`,
{}
);
});
});

View File

@@ -146,7 +146,7 @@ root
shouldHaveRoot
);
});
it('text shouhld wrap with icon', () => {
it('text should wrap with icon', () => {
imgSnapshotTest(
`mindmap
root

View File

@@ -1,7 +1,7 @@
import { imgSnapshotTest } from '../../helpers/util';
describe('packet structure', () => {
it('should render a simple packet diagram', () => {
it('should render a simple packet-beta diagram', () => {
imgSnapshotTest(
`packet-beta
title Hello world
@@ -10,9 +10,18 @@ describe('packet structure', () => {
);
});
it('should render a simple packet diagram', () => {
imgSnapshotTest(
`packet
title Hello world
0-10: "hello"
`
);
});
it('should render a simple packet diagram without ranges', () => {
imgSnapshotTest(
`packet-beta
`packet
0: "h"
1: "i"
`
@@ -21,7 +30,7 @@ describe('packet structure', () => {
it('should render a complex packet diagram', () => {
imgSnapshotTest(
`packet-beta
`packet
0-15: "Source Port"
16-31: "Destination Port"
32-63: "Sequence Number"
@@ -52,7 +61,7 @@ describe('packet structure', () => {
packet:
showBits: false
---
packet-beta
packet
0-15: "Source Port"
16-31: "Destination Port"
32-63: "Sequence Number"

View File

@@ -64,7 +64,7 @@ describe('pie chart', () => {
});
});
it('should render a pie diagram when textPosition is setted', () => {
it('should render a pie diagram when textPosition is set', () => {
imgSnapshotTest(
`pie
"Dogs": 50

View File

@@ -45,7 +45,7 @@ describe('Quadrant Chart', () => {
{}
);
});
it('should able to render y-axix on right side', () => {
it('should able to render y-axis on right side', () => {
imgSnapshotTest(
`
%%{init: {"quadrantChart": {"yAxisPosition": "right"}}}%%
@@ -61,7 +61,7 @@ describe('Quadrant Chart', () => {
{}
);
});
it('should able to render x-axix on bottom', () => {
it('should able to render x-axis on bottom', () => {
imgSnapshotTest(
`
%%{init: {"quadrantChart": {"xAxisPosition": "bottom"}}}%%
@@ -77,7 +77,7 @@ describe('Quadrant Chart', () => {
{}
);
});
it('should able to render x-axix on bottom and y-axis on right', () => {
it('should able to render x-axis on bottom and y-axis on right', () => {
imgSnapshotTest(
`
%%{init: {"quadrantChart": {"xAxisPosition": "bottom", "yAxisPosition": "right"}}}%%

View File

@@ -0,0 +1,79 @@
import { imgSnapshotTest } from '../../helpers/util';
describe('radar structure', () => {
it('should render a simple radar diagram', () => {
imgSnapshotTest(
`radar-beta
title Best Radar Ever
axis A, B, C
curve c1{1, 2, 3}
`
);
});
it('should render a radar diagram with multiple curves', () => {
imgSnapshotTest(
`radar-beta
title Best Radar Ever
axis A, B, C
curve c1{1, 2, 3}
curve c2{2, 3, 1}
`
);
});
it('should render a complex radar diagram', () => {
imgSnapshotTest(
`radar-beta
title My favorite ninjas
axis Agility, Speed, Strength
axis Stam["Stamina"] , Intel["Intelligence"]
curve Ninja1["Naruto Uzumaki"]{
Agility 2, Speed 2,
Strength 3, Stam 5,
Intel 0
}
curve Ninja2["Sasuke"]{2, 3, 4, 1, 5}
curve Ninja3 {3, 2, 1, 5, 4}
showLegend true
ticks 3
max 8
min 0
graticule polygon
`
);
cy.get('svg').should((svg) => {
expect(svg).to.have.length(1);
});
});
it('should render radar diagram with config override', () => {
imgSnapshotTest(
`radar-beta
title Best Radar Ever
axis A,B,C
curve mycurve{1,2,3}`,
{ radar: { marginTop: 100, axisScaleFactor: 0.5 } }
);
});
it('should parse radar diagram with theme override', () => {
imgSnapshotTest(
`radar-beta
axis A,B,C
curve mycurve{1,2,3}`,
{ theme: 'base', themeVariables: { fontSize: 80, cScale0: '#FF0000' } }
);
});
it('should handle radar diagram with radar style override', () => {
imgSnapshotTest(
`radar-beta
axis A,B,C
curve mycurve{1,2,3}`,
{ theme: 'base', themeVariables: { radar: { axisColor: '#FF0000' } } }
);
});
});

View File

@@ -0,0 +1,703 @@
import { imgSnapshotTest, renderGraph } from '../../helpers/util.ts';
const testOptions = [
{ description: '', options: { logLevel: 1 } },
{ description: 'ELK: ', options: { logLevel: 1, layout: 'elk' } },
{ description: 'HD: ', options: { logLevel: 1, look: 'handDrawn' } },
];
describe('Requirement Diagram Unified', () => {
testOptions.forEach(({ description, options }) => {
it(`${description}should render a simple Requirement diagram`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
it(`${description}should render a simple Requirement diagram without htmlLabels`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render a not-so-simple Requirement diagram`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
functionalRequirement test_req2 {
id: 1.1
text: the second test text.
risk: low
verifymethod: inspection
}
performanceRequirement test_req3 {
id: 1.2
text: the third test text.
risk: medium
verifymethod: demonstration
}
interfaceRequirement test_req4 {
id: 1.2.1
text: the fourth test text.
risk: medium
verifymethod: analysis
}
physicalRequirement test_req5 {
id: 1.2.2
text: the fifth test text.
risk: medium
verifymethod: analysis
}
designConstraint test_req6 {
id: 1.2.3
text: the sixth test text.
risk: medium
verifymethod: analysis
}
element test_entity {
type: simulation
}
element test_entity2 {
type: word doc
docRef: reqs/test_entity
}
element test_entity3 {
type: "test suite"
docRef: github.com/all_the_tests
}
test_entity - satisfies -> test_req2
test_req - traces -> test_req2
test_req - contains -> test_req3
test_req3 - contains -> test_req4
test_req4 - derives -> test_req5
test_req5 - refines -> test_req6
test_entity3 - verifies -> test_req5
test_req <- copies - test_entity2
`,
options
);
});
it(`${description}should render a not-so-simple Requirement diagram without htmlLabels`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
functionalRequirement test_req2 {
id: 1.1
text: the second test text.
risk: low
verifymethod: inspection
}
performanceRequirement test_req3 {
id: 1.2
text: the third test text.
risk: medium
verifymethod: demonstration
}
interfaceRequirement test_req4 {
id: 1.2.1
text: the fourth test text.
risk: medium
verifymethod: analysis
}
physicalRequirement test_req5 {
id: 1.2.2
text: the fifth test text.
risk: medium
verifymethod: analysis
}
designConstraint test_req6 {
id: 1.2.3
text: the sixth test text.
risk: medium
verifymethod: analysis
}
element test_entity {
type: simulation
}
element test_entity2 {
type: word doc
docRef: reqs/test_entity
}
element test_entity3 {
type: "test suite"
docRef: github.com/all_the_tests
}
test_entity - satisfies -> test_req2
test_req - traces -> test_req2
test_req - contains -> test_req3
test_req3 - contains -> test_req4
test_req4 - derives -> test_req5
test_req5 - refines -> test_req6
test_entity3 - verifies -> test_req5
test_req <- copies - test_entity2
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render multiple Requirement diagrams`, () => {
imgSnapshotTest(
[
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
],
options
);
});
it(`${description}should render a Requirement diagram with empty information`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
}
element test_entity {
}
`,
options
);
});
it(`${description}should render requirements and elements with and without information`, () => {
renderGraph(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
}
`,
options
);
});
it(`${description}should render requirements and elements with long and short text`, () => {
renderGraph(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text that is long and takes up a lot of space.
risk: high
verifymethod: test
}
element test_entity_name_that_is_extra_long {
}
`,
options
);
});
it(`${description}should render requirements and elements with long and short text without htmlLabels`, () => {
renderGraph(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text that is long and takes up a lot of space.
risk: high
verifymethod: test
}
element test_entity_name_that_is_extra_long {
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render requirements and elements with quoted text for spaces`, () => {
renderGraph(
`
requirementDiagram
requirement "test req name with spaces" {
id: 1
text: the test text that is long and takes up a lot of space.
risk: high
verifymethod: test
}
element "test entity name that is extra long with spaces" {
}
`,
options
);
});
it(`${description}should render requirements and elements with markdown text`, () => {
renderGraph(
`
requirementDiagram
requirement "__my bolded name__" {
id: 1
text: "**Bolded text** _italicized text_"
risk: high
verifymethod: test
}
element "*my italicized name*" {
type: "**Bolded type** _italicized type_"
docref: "*Italicized* __Bolded__"
}
`,
options
);
});
it(`${description}should render requirements and elements with markdown text without htmlLabels`, () => {
renderGraph(
`
requirementDiagram
requirement "__my bolded name__" {
id: 1
text: "**Bolded text** _italicized text_"
risk: high
verifymethod: test
}
element "*my italicized name*" {
type: "**Bolded type** _italicized type_"
docref: "*Italicized* __Bolded__"
}
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render a simple Requirement diagram with a title`, () => {
imgSnapshotTest(
`---
title: simple Requirement diagram
---
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
it(`${description}should render a Requirement diagram with TB direction`, () => {
imgSnapshotTest(
`
requirementDiagram
direction TB
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
it(`${description}should render a Requirement diagram with BT direction`, () => {
imgSnapshotTest(
`
requirementDiagram
direction BT
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
it(`${description}should render a Requirement diagram with LR direction`, () => {
imgSnapshotTest(
`
requirementDiagram
direction LR
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
it(`${description}should render a Requirement diagram with RL direction`, () => {
imgSnapshotTest(
`
requirementDiagram
direction RL
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
it(`${description}should render requirements and elements with styles applied from style statement`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
style test_req,test_entity fill:#f9f,stroke:blue, color:grey, font-weight:bold
`,
options
);
});
it(`${description}should render requirements and elements with styles applied from style statement without htmlLabels`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
style test_req,test_entity fill:#f9f,stroke:blue, color:grey, font-weight:bold
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render requirements and elements with styles applied from class statement`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
classDef bold font-weight: bold
classDef blue stroke:lightblue, color: #0000FF
class test_entity bold
class test_req blue, bold
`,
options
);
});
it(`${description}should render requirements and elements with styles applied from class statement without htmlLabels`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
classDef bold font-weight: bold
classDef blue stroke:lightblue, color: #0000FF
class test_entity bold
class test_req blue, bold
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render requirements and elements with styles applied from classes with shorthand syntax`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req:::blue {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
classDef bold font-weight: bold
classDef blue stroke:lightblue, color: #0000FF
test_entity:::bold
`,
options
);
});
it(`${description}should render requirements and elements with styles applied from classes with shorthand syntax without htmlLabels`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req:::blue {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
classDef bold font-weight: bold
classDef blue stroke:lightblue, color: #0000FF
test_entity:::bold
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render requirements and elements with styles applied from the default class and other styles`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req:::blue {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
classDef blue stroke:lightblue, color:blue
classDef default fill:pink
style test_entity color:green
`,
options
);
});
it(`${description}should render requirements and elements with styles applied from the default class and other styles without htmlLabels`, () => {
imgSnapshotTest(
`
requirementDiagram
requirement test_req:::blue {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
classDef blue stroke:lightblue, color:blue
classDef default fill:pink
style test_entity color:green
`,
{ ...options, htmlLabels: false }
);
});
it(`${description}should render a Requirement diagram with a theme`, () => {
imgSnapshotTest(
`
---
theme: forest
---
requirementDiagram
requirement test_req:::blue {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
`,
options
);
});
});
});

View File

@@ -138,8 +138,8 @@ describe('State diagram', () => {
imgSnapshotTest(
`
stateDiagram-v2
State1: This a a single line description
State2: This a a multi line description
State1: This a single line description
State2: This a multi line description
State2: here comes the multi part
[*] --> State1
State1 --> State2
@@ -345,7 +345,7 @@ stateDiagram
}
);
});
it('v2 width of compond state should grow with title if title is wider', () => {
it('v2 width of compound state should grow with title if title is wider', () => {
imgSnapshotTest(
`
stateDiagram-v2
@@ -402,8 +402,8 @@ stateDiagram-v2
`
stateDiagram-v2
MyState
note left of MyState : I am a leftie
note right of MyState : I am a rightie
note left of MyState : I am a lefty
note right of MyState : I am a righty
`,
{
logLevel: 0,
@@ -552,7 +552,7 @@ style AState fill:#636,border:1px solid red,color:white;
{ logLevel: 0, fontFamily: 'courier' }
);
});
it(' should let styles take preceedence over classes', () => {
it(' should let styles take precedence over classes', () => {
imgSnapshotTest(
`
stateDiagram-v2
@@ -565,7 +565,7 @@ style AState fill:#636,border:1px solid red,color:white;
{ logLevel: 0, fontFamily: 'courier' }
);
});
it(' should allow styles to take effect in stubgraphs', () => {
it(' should allow styles to take effect in subgraphs', () => {
imgSnapshotTest(
`
stateDiagram

View File

@@ -129,8 +129,8 @@ describe('State diagram', () => {
imgSnapshotTest(
`
stateDiagram
State1: This a a single line description
State2: This a a multi line description
State1: This a single line description
State2: This a multi line description
State2: here comes the multi part
[*] --> State1
State1 --> State2

View File

@@ -7,7 +7,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
`,
{}
@@ -35,7 +35,7 @@ describe('Timeline diagram', () => {
section Stone Age
7600 BC : Britain's oldest known house was built in Orkney, Scotland
6000 BC : Sea levels rise and Britain becomes an island.<br> The people who live here are hunter-gatherers.
section Broze Age
section Bronze Age
2300 BC : People arrive from Europe and settle in Britain. <br>They bring farming and metalworking.
: New styles of pottery and ways of burying the dead appear.
2200 BC : The last major building works are completed at Stonehenge.<br> People now bury their dead in stone circles.
@@ -51,7 +51,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
`,
{}
@@ -68,7 +68,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -84,7 +84,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -101,7 +101,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -118,7 +118,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -135,7 +135,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -152,7 +152,7 @@ describe('Timeline diagram', () => {
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -161,4 +161,68 @@ describe('Timeline diagram', () => {
{}
);
});
it('11: should render timeline with many stacked events and proper timeline line length', () => {
imgSnapshotTest(
`timeline
title Medical Device Lifecycle
section Pre-Development
Quality Management System : Regulatory Compliance : Risk Management
section Development
Management Responsibility : Planning Activities : Human Resources
Resource Management : Management Reviews : Infrastructure
section Post-Development
Product Realization Activities : Planning Activities : Customer-related Processes
Post-Production Activities : Feedback : Complaints : Adverse Events
: Research and Development : Purchasing Activities
: Production Activities : Installation Activities
: Servicing Activities : Post-Market Surveillance
`,
{}
);
});
it('12: should render timeline with proper vertical line lengths for all columns', () => {
imgSnapshotTest(
`---
config:
theme: base
themeVariables:
fontFamily: Fira Sans
fontSize: 17px
cScale0: '#b3cde0'
cScale1: '#f49090'
cScale2: '#85d5b8'
---
timeline
title Medical Device Lifecycle
section Planning
Quality Management System (4): Regulatory Compliance (4.1.1)
: Risk Management (4.1.2)
Management Resposibility (5): Planning Activities (5.4)
: Management Reviews (5.6)
Resource Management (6): Human Resources (6.2)
: Infrastructure (6.3)
section Realization
Research and Development (7.3): RnD Planning (7.3.2)
: Inputs (7.3.3)
: Outputs (7.3.4)
: Review (7.3.5)
: Verification (7.3.6)
: Validation (7.3.7)
Purchasing (7.4): Purchasing Process (7.4.1)
: Purchasing Information (7.4.2)
Production (7.5): Production Activities (7.5.1)
: Production Feedback (8.2.1)
Installation (7.5.3): Installation Activities (7.5.3)
Servicing (7.5.4): Servicing Activities (7.5.4)
section Post-Production
Post-Market Activities (8): Feedback (8.2.1)
: Complaints (8.2.2)
: Adverse Events (8.2.3)
`,
{}
);
});
});

View File

@@ -0,0 +1,382 @@
import { imgSnapshotTest } from '../../helpers/util.ts';
describe('Treemap Diagram', () => {
it('1: should render a basic treemap', () => {
imgSnapshotTest(
`treemap-beta
"Category A"
"Item A1": 10
"Item A2": 20
"Category B"
"Item B1": 15
"Item B2": 25
`,
{}
);
});
it('2: should render a hierarchical treemap', () => {
imgSnapshotTest(
`treemap-beta
"Products"
"Electronics"
"Phones": 50
"Computers": 30
"Accessories": 20
"Clothing"
"Men's"
"Shirts": 10
"Pants": 15
"Women's"
"Dresses": 20
"Skirts": 10
`,
{}
);
});
it('3: should render a treemap with styling using classDef', () => {
imgSnapshotTest(
`treemap-beta
"Section 1"
"Leaf 1.1": 12
"Section 1.2":::class1
"Leaf 1.2.1": 12
"Section 2"
"Leaf 2.1": 20:::class1
"Leaf 2.2": 25
"Leaf 2.3": 12
classDef class1 fill:red,color:blue,stroke:#FFD600;
`,
{}
);
});
it('4: should handle long text that wraps', () => {
imgSnapshotTest(
`treemap-beta
"Main Category"
"This is a very long item name that should wrap to the next line when rendered in the treemap diagram": 50
"Short item": 20
`,
{}
);
});
it('5: should render with a forest theme', () => {
imgSnapshotTest(
`---
config:
theme: forest
---
treemap-beta
"Category A"
"Item A1": 10
"Item A2": 20
"Category B"
"Item B1": 15
"Item B2": 25
`,
{}
);
});
it('6: should handle multiple levels of nesting', () => {
imgSnapshotTest(
`treemap-beta
"Level 1"
"Level 2A"
"Level 3A": 10
"Level 3B": 15
"Level 2B"
"Level 3C": 20
"Level 3D"
"Level 4A": 5
"Level 4B": 5
`,
{}
);
});
it('7: should handle classDef with multiple styles', () => {
imgSnapshotTest(
`treemap-beta
"Main"
"A": 20
"B":::important
"B1": 10
"B2": 15
"C": 5:::secondary
classDef important fill:#f96,stroke:#333,stroke-width:2px;
classDef secondary fill:#6cf,stroke:#333,stroke-dasharray:5 5;
`,
{}
);
});
it('8: should handle dollar value formatting with thousands separator', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: "$0,0"
---
treemap
"Budget"
"Operations"
"Salaries": 700000
"Equipment": 200000
"Supplies": 100000
"Marketing"
"Advertising": 400000
"Events": 100000
`,
{}
);
});
it('8a: should handle percentage formatting', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: ".1%"
---
treemap-beta
"Market Share"
"Company A": 0.35
"Company B": 0.25
"Company C": 0.15
"Others": 0.25
`,
{}
);
});
it('8b: should handle decimal formatting', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: ".2f"
---
treemap-beta
"Metrics"
"Conversion Rate": 0.0567
"Bounce Rate": 0.6723
"Click-through Rate": 0.1289
"Engagement": 0.4521
`,
{}
);
});
it('8c: should handle dollar sign with decimal places', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: "$.2f"
---
treemap-beta
"Product Prices"
"Basic": 19.99
"Standard": 49.99
"Premium": 99.99
"Enterprise": 199.99
`,
{}
);
});
it('8d: should handle dollar sign with thousands separator and decimal places', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: "$,.2f"
---
treemap-beta
"Revenue"
"Q1": 1250345.75
"Q2": 1645789.25
"Q3": 1845123.50
"Q4": 2145678.75
`,
{}
);
});
it('8e: should handle simple thousands separator', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: ","
---
treemap-beta
"User Counts"
"Active Users": 1250345
"New Signups": 45789
"Churned": 12350
"Converted": 78975
`,
{}
);
});
it('8f: should handle valueFormat set via directive with dollar and thousands separator', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: "$,.0f"
---
treemap-beta
"Sales by Region"
"North": 1234567
"South": 7654321
"East": 4567890
"West": 9876543
`,
{}
);
});
it('8g: should handle scientific notation format', () => {
imgSnapshotTest(
`---
config:
treemap:
valueFormat: ".2e"
---
treemap-beta
"Scientific Values"
"Value 1": 1234567
"Value 2": 0.0000123
"Value 3": 1000000000
`,
{}
);
});
it('9: should handle a complex example with multiple features', () => {
imgSnapshotTest(
`---
config:
theme: dark
treemap:
valueFormat: "$0,0"
---
treemap-beta
"Company Budget"
"Engineering":::engineering
"Frontend": 300000
"Backend": 400000
"DevOps": 200000
"Marketing":::marketing
"Digital": 250000
"Print": 100000
"Events": 150000
"Sales":::sales
"Direct": 500000
"Channel": 300000
classDef engineering fill:#6b9bc3,stroke:#333;
classDef marketing fill:#c36b9b,stroke:#333;
classDef sales fill:#c3a66b,stroke:#333;
`,
{}
);
});
it('10: should render the example from documentation', () => {
imgSnapshotTest(
`
treemap-beta
"Section 1"
"Leaf 1.1": 12
"Section 1.2":::class1
"Leaf 1.2.1": 12
"Section 2"
"Leaf 2.1": 20:::class1
"Leaf 2.2": 25
"Leaf 2.3": 12
classDef class1 fill:red,color:blue,stroke:#FFD600;
`,
{}
);
});
it('11: should handle comments', () => {
imgSnapshotTest(
`
treemap-beta
%% This is a comment
"Category A"
"Item A1": 10
"Item A2": 20
%% Another comment
"Category B"
"Item B1": 15
"Item B2": 25
`,
{}
);
});
/*
it.skip('12: should render a treemap with title', () => {
imgSnapshotTest(
`
treemap-beta
title Treemap with Title
"Category A"
"Item A1": 10
"Item A2": 20
"Category B"
"Item B1": 15
"Item B2": 25
`,
{}
);
});
it.skip('13: should render a treemap with accessibility attributes', () => {
imgSnapshotTest(
`
treemap-beta
accTitle: Accessible Treemap Title
accDescr: This is a description of the treemap for accessibility purposes
"Category A"
"Item A1": 10
"Item A2": 20
"Category B"
"Item B1": 15
"Item B2": 25
`,
{}
);
});
it.skip('14: should render a treemap with title and accessibility attributes', () => {
imgSnapshotTest(
`
treemap
title Treemap with Title and Accessibility
accTitle: Accessible Treemap Title
accDescr: This is a description of the treemap for accessibility purposes
"Category A"
"Item A1": 10
"Item A2": 20
"Category B"
"Item B1": 15
"Item B2": 25
`,
{}
);
});
*/
});

View File

@@ -179,6 +179,7 @@ describe('XY Chart', () => {
axisLineWidth: 5
chartOrientation: horizontal
plotReservedSpacePercent: 60
showDataLabel: true
---
xychart-beta
title "Sales Revenue"
@@ -315,4 +316,516 @@ describe('XY Chart', () => {
);
cy.get('svg');
});
it('should render vertical bar chart with labels', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec]
y-axis "Revenue (in $)" 4000 --> 11000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]
`,
{}
);
});
it('should render horizontal bar chart with labels', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec]
y-axis "Revenue (in $)" 4000 --> 11000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]
`,
{}
);
});
it('should render vertical bar chart without labels by default', () => {
imgSnapshotTest(
`
xychart-beta
title "Sales Revenue"
x-axis Months [jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec]
y-axis "Revenue (in $)" 4000 --> 11000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]
`,
{}
);
});
it('should render horizontal bar chart without labels by default', () => {
imgSnapshotTest(
`
---
config:
xyChart:
chartOrientation: horizontal
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec]
y-axis "Revenue (in $)" 4000 --> 11000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]
`,
{}
);
});
it('should render multiple bar plots vertically with labels correctly', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Multiple Bar Plots"
x-axis Categories [A, B, C]
y-axis "Values" 0 --> 100
bar [10, 50, 90]
`,
{}
);
});
it('should render multiple bar plots horizontally with labels correctly', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Multiple Bar Plots"
x-axis Categories [A, B, C]
y-axis "Values" 0 --> 100
bar [10, 50, 90]
`,
{}
);
});
it('should render a single bar with label for a vertical xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Single Bar Chart"
x-axis Categories [A]
y-axis "Value" 0 --> 100
bar [75]
`,
{}
);
});
it('should render a single bar with label for a horizontal xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Single Bar Chart"
x-axis Categories [A]
y-axis "Value" 0 --> 100
bar [75]
`,
{}
);
});
it('should render negative and decimal values with correct labels for vertical xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Decimal and Negative Values"
x-axis Categories [A, B, C]
y-axis -10 --> 10
bar [ -2.5, 0.75, 5.1 ]
`,
{}
);
});
it('should render negative and decimal values with correct labels for horizontal xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Decimal and Negative Values"
x-axis Categories [A, B, C]
y-axis -10 --> 10
bar [ -2.5, 0.75, 5.1 ]
`,
{}
);
});
it('should render data labels within each bar in the vertical xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan,b,c]
y-axis "Revenue (in $)" 4000 --> 12000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000, 3000, 2000, 500, 2000, 3000, 11000, 5000, 6000]
`,
{}
);
cy.get('g.bar-plot-0').within(() => {
cy.get('rect').each(($rect, index) => {
// Extract bar properties
const barProps = {
x: parseFloat($rect.attr('x')),
y: parseFloat($rect.attr('y')),
width: parseFloat($rect.attr('width')),
height: parseFloat($rect.attr('height')),
};
// Get the text element corresponding to this bar by index.
cy.get('text')
.eq(index)
.then(($text) => {
const bbox = $text[0].getBBox();
const textProps = {
x: bbox.x,
y: bbox.y,
width: bbox.width,
height: bbox.height,
};
// Verify that the text label is positioned within the boundaries of the bar.
expect(textProps.x).to.be.greaterThan(barProps.x);
expect(textProps.x + textProps.width).to.be.lessThan(barProps.x + barProps.width);
// Check horizontal alignment (within tolerance)
expect(textProps.x + textProps.width / 2).to.be.closeTo(
barProps.x + barProps.width / 2,
5
);
expect(textProps.y).to.be.greaterThan(barProps.y);
expect(textProps.y + textProps.height).to.be.lessThan(barProps.y + barProps.height);
});
});
});
});
it('should render data labels within each bar in the horizontal xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan,b,c]
y-axis "Revenue (in $)" 4000 --> 12000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000, 3000, 2000, 500, 2000, 3000, 11000, 5000, 6000]
`,
{}
);
cy.get('g.bar-plot-0').within(() => {
cy.get('rect').each(($rect, index) => {
// Extract bar properties
const barProps = {
x: parseFloat($rect.attr('x')),
y: parseFloat($rect.attr('y')),
width: parseFloat($rect.attr('width')),
height: parseFloat($rect.attr('height')),
};
// Get the text element corresponding to this bar by index.
cy.get('text')
.eq(index)
.then(($text) => {
const bbox = $text[0].getBBox();
const textProps = {
x: bbox.x,
y: bbox.y,
width: bbox.width,
height: bbox.height,
};
// Verify that the text label is positioned within the boundaries of the bar.
expect(textProps.x).to.be.greaterThan(barProps.x);
expect(textProps.x + textProps.width).to.be.lessThan(barProps.x + barProps.width);
expect(textProps.y).to.be.greaterThan(barProps.y);
expect(textProps.y + textProps.height).to.be.lessThan(barProps.y + barProps.height);
expect(textProps.y + textProps.height / 2).to.be.closeTo(
barProps.y + barProps.height / 2,
5
);
});
});
});
});
it('should render data labels within each bar in the vertical xy-chart with a lot of bars of different sizes', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan,a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s]
y-axis "Revenue (in $)" 4000 --> 12000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000, 8000, 10000, 5000, 7600, 4999,11000 ,5000,6000]
`,
{}
);
cy.get('g.bar-plot-0').within(() => {
cy.get('rect').each(($rect, index) => {
// Extract bar properties
const barProps = {
x: parseFloat($rect.attr('x')),
y: parseFloat($rect.attr('y')),
width: parseFloat($rect.attr('width')),
height: parseFloat($rect.attr('height')),
};
// Get the text element corresponding to this bar by index.
cy.get('text')
.eq(index)
.then(($text) => {
const bbox = $text[0].getBBox();
const textProps = {
x: bbox.x,
y: bbox.y,
width: bbox.width,
height: bbox.height,
};
// Verify that the text label is positioned within the boundaries of the bar.
expect(textProps.x).to.be.greaterThan(barProps.x);
expect(textProps.x + textProps.width).to.be.lessThan(barProps.x + barProps.width);
// Check horizontal alignment (within tolerance)
expect(textProps.x + textProps.width / 2).to.be.closeTo(
barProps.x + barProps.width / 2,
5
);
expect(textProps.y).to.be.greaterThan(barProps.y);
expect(textProps.y + textProps.height).to.be.lessThan(barProps.y + barProps.height);
});
});
});
});
it('should render data labels within each bar in the horizontal xy-chart with a lot of bars of different sizes', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan,a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s]
y-axis "Revenue (in $)" 4000 --> 12000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000, 8000, 10000, 5000, 7600, 4999,11000 ,5000,6000]
`,
{}
);
cy.get('g.bar-plot-0').within(() => {
cy.get('rect').each(($rect, index) => {
// Extract bar properties
const barProps = {
x: parseFloat($rect.attr('x')),
y: parseFloat($rect.attr('y')),
width: parseFloat($rect.attr('width')),
height: parseFloat($rect.attr('height')),
};
// Get the text element corresponding to this bar by index.
cy.get('text')
.eq(index)
.then(($text) => {
const bbox = $text[0].getBBox();
const textProps = {
x: bbox.x,
y: bbox.y,
width: bbox.width,
height: bbox.height,
};
// Verify that the text label is positioned within the boundaries of the bar.
expect(textProps.x).to.be.greaterThan(barProps.x);
expect(textProps.x + textProps.width).to.be.lessThan(barProps.x + barProps.width);
expect(textProps.y).to.be.greaterThan(barProps.y);
expect(textProps.y + textProps.height).to.be.lessThan(barProps.y + barProps.height);
expect(textProps.y + textProps.height / 2).to.be.closeTo(
barProps.y + barProps.height / 2,
5
);
});
});
});
});
it('should render data labels correctly for a bar in the vertical xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan]
y-axis "Revenue (in $)" 3000 --> 12000
bar [4000]
`,
{}
);
cy.get('g.bar-plot-0').within(() => {
cy.get('rect').each(($rect, index) => {
// Extract bar properties
const barProps = {
x: parseFloat($rect.attr('x')),
y: parseFloat($rect.attr('y')),
width: parseFloat($rect.attr('width')),
height: parseFloat($rect.attr('height')),
};
// Get the text element corresponding to this bar by index.
cy.get('text')
.eq(index)
.then(($text) => {
const bbox = $text[0].getBBox();
const textProps = {
x: bbox.x,
y: bbox.y,
width: bbox.width,
height: bbox.height,
};
// Verify that the text label is positioned within the boundaries of the bar.
expect(textProps.x).to.be.greaterThan(barProps.x);
expect(textProps.x + textProps.width).to.be.lessThan(barProps.x + barProps.width);
// Check horizontal alignment (within tolerance)
expect(textProps.x + textProps.width / 2).to.be.closeTo(
barProps.x + barProps.width / 2,
5
);
expect(textProps.y).to.be.greaterThan(barProps.y);
expect(textProps.y + textProps.height).to.be.lessThan(barProps.y + barProps.height);
});
});
});
});
it('should render data labels correctly for a bar in the horizontal xy-chart', () => {
imgSnapshotTest(
`
---
config:
xyChart:
showDataLabel: true
chartOrientation: horizontal
---
xychart-beta
title "Sales Revenue"
x-axis Months [jan]
y-axis "Revenue (in $)" 3000 --> 12000
bar [4000]
`,
{}
);
cy.get('g.bar-plot-0').within(() => {
cy.get('rect').each(($rect, index) => {
// Extract bar properties
const barProps = {
x: parseFloat($rect.attr('x')),
y: parseFloat($rect.attr('y')),
width: parseFloat($rect.attr('width')),
height: parseFloat($rect.attr('height')),
};
// Get the text element corresponding to this bar by index.
cy.get('text')
.eq(index)
.then(($text) => {
const bbox = $text[0].getBBox();
const textProps = {
x: bbox.x,
y: bbox.y,
width: bbox.width,
height: bbox.height,
};
// Verify that the text label is positioned within the boundaries of the bar.
expect(textProps.x).to.be.greaterThan(barProps.x);
expect(textProps.x + textProps.width).to.be.lessThan(barProps.x + barProps.width);
expect(textProps.y).to.be.greaterThan(barProps.y);
expect(textProps.y + textProps.height).to.be.lessThan(barProps.y + barProps.height);
expect(textProps.y + textProps.height / 2).to.be.closeTo(
barProps.y + barProps.height / 2,
5
);
});
});
});
});
});

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"
@@ -30,8 +30,8 @@
.mermaid svg {
/* font-size: 18px !important; */
background-color: #eee;
background-image: radial-gradient(#fff 1%, transparent 11%),
radial-gradient(#fff 1%, transparent 11%);
background-image:
radial-gradient(#fff 1%, transparent 11%), radial-gradient(#fff 1%, transparent 11%);
background-size: 20px 20px;
background-position:
0 0,
@@ -60,7 +60,7 @@
<pre id="diagram" class="mermaid2">
timeline
title My day
section section with no tasks
section Section with no tasks
section Go to work at the dog office
1930 : first step : second step is a long step
: third step
@@ -70,18 +70,18 @@
1960 : India fights poverty, looses war to China and gets nuclear weapons from USA and USSR
1970 : Green Revolution comes to india
section Another section with no tasks
I am a big big big tasks
I am not so big tasks
I am a very, very big task
I am not so big task
</pre>
<pre id="diagram" class="mermaid">
timeline
title MermaidChart 2023 Timeline
section 2023 Q1 <br> Release Personal Tier
Buttet 1 : sub-point 1a : sub-point 1b
Bullet 1 : sub-point 1a : sub-point 1b
: sub-point 1c
Bullet 2 : sub-point 2a : sub-point 2b
section 2023 Q2 <br> Release XYZ Tier
Buttet 3 : sub-point <br> 3a : sub-point 3b
Bullet 3 : sub-point <br> 3a : sub-point 3b
: sub-point 3c
Bullet 4 : sub-point 4a : sub-point 4b
@@ -93,7 +93,7 @@
section Stone Age
7600 BC : Britain's oldest known house was built in Orkney, Scotland
6000 BC : Sea levels rise and Britain becomes an island. The people who live here are hunter-gatherers.
section Broze Age
section Bronze Age
2300 BC : People arrive from Europe and settle in Britain. They bring farming and metalworking.
: New styles of pottery and ways of burying the dead appear.
2200 BC : The last major building works are completed at Stonehenge. People now bury their dead in stone circles.
@@ -106,7 +106,7 @@
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google : Pixar
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008s : Instagram
@@ -122,7 +122,7 @@
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google : Pixar
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008s : Instagram
@@ -139,7 +139,7 @@
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008 : Instagram
@@ -152,7 +152,7 @@
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook : Google
2005 : Youtube
2005 : YouTube
2006 : Twitter
2007 : Tumblr
2008s : Instagram

View File

@@ -3,7 +3,7 @@
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"
@@ -37,7 +37,7 @@
+String owner
+BigDecimal balance
+deposit(amount) bool
+withdrawl(amount) int
+withdrawal(amount) int
}
cssClass "BankAccount" customCss
@@ -56,7 +56,7 @@ classE o-- classF : aggregation
+String owner
+BigDecimal balance
+deposit(amount) bool
+withdrawl(amount) int
+withdrawal(amount) int
}
Class01~T~ <|-- AveryLongClass : Cool
Class03~T~ *-- Class04~T~

View File

@@ -77,7 +77,7 @@
document.getElementsByTagName('body')[0].appendChild(div);
}
mermaid.initialize({ startOnLoad: true, securityLevel: 'strct', logLevel: 1 });
mermaid.initialize({ startOnLoad: true, securityLevel: 'strict_', logLevel: 1 });
</script>
</body>
</html>

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"
@@ -31,7 +31,7 @@
flowchart BT subgraph S1 sub1 -->sub2 end subgraph S2 sub4 end S1 --> S2 sub1 --> sub4
</div>
<div class="mermaid2" style="width: 50%; height: 200px">
sequenceDiagram Alice->>Bob:Extremely utterly long line of longness which had preivously
sequenceDiagram Alice->>Bob:Extremely utterly long line of longness which had previously
overflown the actor box as it is much longer than what it should be Bob->>Alice: I'm short
though
</div>
@@ -61,9 +61,9 @@
#quot;elit#quot;."}}
</div>
<div class="mermaid2" style="width: 50%; height: 50%">
flowchart TB internet nat routeur lb1 lb2 compute1 compute2 subgraph project routeur nat
subgraph subnet1 compute1 lb1 end subgraph subnet2 compute2 lb2 end end internet --> routeur
routeur --> subnet1 & subnet2 subnet1 & subnet2 --> nat --> internet
flowchart TB internet nat router lb1 lb2 compute1 compute2 subgraph project router nat
subgraph subnet1 compute1 lb1 end subgraph subnet2 compute2 lb2 end end internet --> router
router --> subnet1 & subnet2 subnet1 & subnet2 --> nat --> internet
</div>
<div class="mermaid2" style="width: 50%; height: 50%">
flowchart TD subgraph one[One] subgraph sub_one[Sub One] _sub_one end end subgraph two[Two]

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -7,7 +7,7 @@
rel="stylesheet"
/>
<style>
svg {
svg:not(svg svg) {
border: 2px solid darkred;
}
.exClass2 > rect,

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -3,7 +3,7 @@
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"
@@ -38,7 +38,7 @@
+String owner
+BigDecimal balance
+deposit(amount) bool
+withdrawl(amount) int
+withdrawal(amount) int
}
cssClass "BankAccount" customCss
</pre>

View File

@@ -3,7 +3,7 @@
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -3,7 +3,7 @@
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"
@@ -30,8 +30,8 @@
.mermaid svg {
/* font-size: 18px !important; */
background-color: #efefef;
background-image: radial-gradient(#fff 51%, transparent 91%),
radial-gradient(#fff 51%, transparent 91%);
background-image:
radial-gradient(#fff 51%, transparent 91%), radial-gradient(#fff 51%, transparent 91%);
background-size: 20px 20px;
background-position:
0 0,

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"

View File

@@ -4,12 +4,16 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"
rel="stylesheet"
/>
<link
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css"
rel="stylesheet"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"
rel="stylesheet"
@@ -28,19 +32,40 @@
href="https://fonts.googleapis.com/css2?family=Kalam:wght@300;400;700&family=Rubik+Mono+One&display=swap"
rel="stylesheet"
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
href="https://fonts.googleapis.com/css2?family=Recursive:wght@300..1000&display=swap"
rel="stylesheet"
/>
<style>
.recursive-mermaid {
font-family: 'Recursive', sans-serif;
font-optical-sizing: auto;
font-weight: 500;
font-style: normal;
font-variation-settings:
'slnt' 0,
'CASL' 0,
'CRSV' 0.5,
'MONO' 0;
}
body {
/* background: rgb(221, 208, 208); */
/* background: #333; */
font-family: 'Arial';
/* color: white; */
/* font-size: 18px !important; */
}
h1 {
color: grey;
}
.mermaid {
border: 1px solid red;
}
.mermaid2 {
display: none;
}
@@ -73,363 +98,404 @@
font-family: monospace;
font-size: 72px;
}
pre {
width: 100%;
}
.class2 {
fill: red;
fill-opacity: 1;
}
/* tspan {
font-size: 6px !important;
} */
/* .flowchart-link {
stroke-dasharray: 4, 4 !important;
animation: flow 1s linear infinite;
animation: dashdraw 4.93282s linear infinite;
stroke-width: 2px !important;
} */
@keyframes dashdraw {
from {
stroke-dashoffset: 0;
}
}
/*stroke-width:2;stroke-dasharray:10.000000,9.865639;stroke-dashoffset:-198.656393;animation: 4.932820s linear infinite;*/
/* stroke-width:2;stroke-dasharray:10.000000,9.865639;stroke-dashoffset:-198.656393;animation: dashdraw 4.932820s linear infinite;*/
</style>
</head>
<body>
<div class="flex">
<pre id="diagram" class="mermaid2">
---
title: hello2
config:
look: handDrawn
layout: elk
elk:
<!-- nodePlacementStrategy: INTERACTIVE -->
<!-- mergeEdges: true -->
---
stateDiagram-v2
direction LR
accTitle: An idealized Open Source supply-chain graph
<pre id="diagram4" class="mermaid">
treemap
"Section 1"
"Leaf 1.1": 12
"Section 1.2":::class1
"Leaf 1.2.1": 12
"Section 2"
"Leaf 2.1": 20:::class1
"Leaf 2.2": 25
"Leaf 2.3": 12
%%
state "🟦 Importer" as author_importer
state "🟥 Supplier, Owner" as author_owner
state "🟨🟥 Maintainer, Author\n🟨 Custodian" as author
state "🟩 Distributor" as repository_distributor
state "🟦 Importer" as language_importer
state "🟦🟨 Packager" as language_packager
state "🟦🟨 OSS Steward" as language_steward
state "🟨 Curator" as language_curator
state "🟩 Distributor" as language_distributor
state "🟦 Contributor" as contributor
state "🟦 Importer" as package_importer
state "🟨 Patcher" as package_patcher
state "🟨🟦 Builder\n🟨🟦 Packager\n🟨🟦 Containerizer" as package_packager
state "🟨 Curator" as package_curator
state "🟩 Distributor" as package_distributor
state "🟦 Importer" as integrator_importer
state "🟥 Supplier, Manufacturer, Owner" as integrator_owner
state "🟦🟨🟥 Integrator, Developer" as integrator_developer
state "🟩🟨 SBOM Redactor\n🟩 Publisher" as integrator_publisher
state "🟦🟨 Builder" as integrator_builder
state "🟨 Deployer" as deployer
state "🟦 Vuln. Checker" as integrator_checker
state "🟩🟨 SBOM Redactor" as redactor
state "🟦 Consumer\n🟦 User" as consumer
state "🟦 Auditor" as auditor_internal
state "🟦 Auditor" as auditor_external
%%
classDef createsSBOM stroke:red,stroke-width:3px;
classDef updatesSBOM stroke:yellow,stroke-width:3px;
classDef assemblesSBOM stroke:yellow,stroke-width:3px;
classDef distributesSBOM stroke:green,stroke-width:3px;
classDef verifiesSBOM stroke:#07f,stroke-width:3px;
%%
class author_importer verifiesSBOM
class author_owner createsSBOM
class manufacturer_owner createsSBOM
class author assemblesSBOM
class package_importer verifiesSBOM
class package_patcher updatesSBOM
class package_packager assemblesSBOM
class package_curator distributesSBOM
class package_distributor distributesSBOM
class language_importer verifiesSBOM
class language_packager assemblesSBOM
class language_steward updatesSBOM
class language_curator distributesSBOM
class language_distributor distributesSBOM
class repository_distributor distributesSBOM
class integrator_importer verifiesSBOM
class integrator_owner createsSBOM
class integrator_developer assemblesSBOM
class integrator_publisher distributesSBOM
class integrator_builder assemblesSBOM
class integrator_checker verifiesSBOM
class deployer assemblesSBOM
class redactor distributesSBOM
class auditor_internal verifiesSBOM
class auditor_external verifiesSBOM
state "Maintainer Environment" as environment_maintainer {
[*] --> author_importer
[*] --> author
author_importer --> author
author_owner --> author
author --> language_packager
}
[*] --> environment_maintainer
state "Language Ecosystem" as ecosystem_lang {
[*] --> language_importer
[*] --> language_steward
[*] --> language_curator
[*] --> language_distributor
language_importer --> language_distributor
language_importer --> language_curator
language_steward --> language_curator
language_curator --> language_distributor
}
language_packager --> ecosystem_lang
ecosystem_lang --> ecosystem_lang
state "Public Collaboration Ecosystem" as ecosystem_repo {
[*] --> repository_distributor
}
author --> ecosystem_repo
ecosystem_repo --> author
repository_distributor --> contributor
contributor --> repository_distributor
state "Package Ecosystem" as ecosystem_package {
[*] --> package_importer
[*] --> package_packager
[*] --> package_patcher
package_importer --> package_patcher
package_importer --> package_packager
package_patcher --> package_packager
package_packager --> package_curator
package_packager --> package_distributor
package_curator --> package_distributor
}
repository_distributor --> ecosystem_package
language_distributor --> ecosystem_package
ecosystem_package --> ecosystem_package
state "Integrator Environment" as environment_integrator {
[*] --> integrator_developer
[*] --> integrator_importer
integrator_importer --> integrator_developer
integrator_owner --> integrator_developer
integrator_builder --> integrator_publisher
integrator_developer --> integrator_checker
integrator_checker --> integrator_developer
auditor_internal --> integrator_developer
integrator_developer --> integrator_builder
integrator_developer --> auditor_internal
}
repository_distributor --> environment_integrator
language_distributor --> environment_integrator
package_distributor --> environment_integrator
state "Production Environment" as environment_prod {
[*] --> deployer
deployer --> redactor
}
integrator_publisher --> [*]
integrator_developer --> environment_prod
integrator_builder --> environment_prod
integrator_publisher --> environment_prod
deployer --> auditor_external
deployer --> consumer
redactor --> consumer
</pre>
<pre id="diagram" class="mermaid2">
---
config:
look: neo
---
flowchart RL
subgraph " "
A5@{ shape: manual-file, label: "a label"}
B5@{ shape: manual-input, label: "a label" }
C5@{ shape: mul-doc, label: "a label" }
D5@{ shape: mul-proc, label: "a label" }
E5@{ shape: paper-tape, label: "a label" }
B3@{ shape: das, label: "a label" }
C3@{ shape: disk, label: "a label" }
D4@{ shape: lin-doc, label: "a label" }
E4@{ shape: loop-limit, label: "a label" }
end
subgraph " "
B6@{ shape: summary, label: "a label" }
C6@{ shape: tag-we-rect, label: "a label" }
D6@{ shape: tag-rect, label: "a label" }
A2@{ shape: fork}
B2@{ shape: hourglass }
C2@{ shape: comment, label: "I am a comment" }
D2@{ shape: bolt }
D3@{ shape: disp, label: "a label" }
C4@{ shape: junction, label: "a label" }
A4@{ shape: extract, label: "a label"}
B52[a fr]@{ shape: fr }
end
subgraph " "
A1@{ shape: text, label: This is a textblock}
B1@{ shape: card, label: "a label" }
C1@{ shape: lined-proc, label: "a label" }
D1@{ shape: start, label: "a label" }
E1@{ shape: stop, label: "a label" }
E2@{ shape: doc, label: "a label" }
A6@{ shape: stored-data, label: "a label"}
A3@{ shape: delay, label: "a label" }
E3@{ shape: div-proc, label: "a label" }
B4[a label]@{ shape: win-pane }
end
</pre>
<pre id="diagram" class="mermaid2">
---
title: hello2
config:
look: handDrawn
elk:
<!-- nodePlacementStrategy: SIMPLE -->
---
%%{init: {"flowchart": {"defaultRenderer": "elk"}} }%%
flowchart TD
A([Start]) -->|go to booking page| B("select
ISBS booking no")
A --> QQ{cancel booking}
A --> RR{no show}
A --> SS{change booking}
B -->C(wmpay_request_payment.request_type= 'partial',
wmpay_request_payment.status= 'paid',
pos_booking.booking_status= partial and 'full_deposit')
style C text-align:left
C -->D{manage booking}
D -->|cancel|E[ระบบแสดงช่องให้กรอกเหตุผล]
E -->F{กดปุ่ม 'cancel' หรือไม่}
F -->|Yes|G[ระบบบันทึกค่าใหม่
และไม่สามารถแก้ไขข้อมูลได้]
F -->|No|H[กดปุ่ม 'close']
H -->|ระบบไม่เปลี่ยนแปลงข้อมูล|Z
G -->|ระบบส่งข้อมูล|I[(POS_database)]
I -->|pos_booking.booking_status='cancel'|Z([End])
D -->|no show|J[ระบบแสดงช่องให้กรอกเหตุผล]
J -->K{กดปุ่ม 'noshow' หรือไม่}
K -->|Yes|L[ระบบสร้างใบเสร็จอัตโนมัติ
Product_id: 439,
ItemName: no show]
style L text-align:left
K -->|No|O[กดปุ่ม 'close']
O -->|ระบบไม่เปลี่ยนแปลงข้อมูล|Z
L -->M[ระบบบันทึกค่าใหม่]
M -->|ระบบส่งข้อมูล|N[(POS_database)]
N -->|pos_booking.booking_status=noshow|Z
</pre>
<pre id="diagram" class="mermaid2">
---
title: hello2
config:
look: handDrawn
layout: dagre
elk:
nodePlacementStrategy: BRANDES_KOEPF
---
flowchart
A --> A
subgraph A
B --> B
subgraph B
C
end
end
classDef class1 fill:red,color:blue,stroke:#FFD600;
</pre
>
<pre id="diagram" class="mermaid2">
>
<pre id="diagram4" class="mermaid2">
---
config:
look: handdrawn
flowchart:
htmlLabels: true
treemap:
valueFormat: '$0,0'
---
flowchart
A[I am a long text, where do I go??? handdrawn - true]
</pre
>
</div>
<div class="flex">
<pre id="diagram" class="mermaid2">
---
config:
flowchart:
htmlLabels: false
---
flowchart
A[I am a long text, where do I go??? classic - false]
</pre
>
<pre id="diagram" class="mermaid2">
---
config:
flowchart:
htmlLabels: true
---
flowchart
A[I am a long text, where do I go??? classic - true]
</pre
>
</div>
<pre id="diagram2" class="mermaid2">
flowchart LR
id1(Start)-->id2(Stop)
style id1 fill:#f9f,stroke:#333,stroke-width:4px
style id2 fill:#bbf,stroke:#f66,stroke-width:2px,color:#fff,stroke-dasharray: 5 5
treemap
"Budget"
"Operations"
"Salaries": 7000
"Equipment": 2000
"Supplies": 1000
"Marketing"
"Advertising": 4000
"Events": 1000
</pre
>
<pre id="diagram4" class="mermaid">
treemap
title Accessible Treemap Title
"Category A"
"Item A1": 10
"Item A2": 20
"Category B"
"Item B1": 15
"Item B2": 25
</pre>
<pre id="diagram3" class="mermaid2">
<pre id="diagram4" class="mermaid2">
flowchart LR
A:::foo & B:::bar --> C:::foobar
classDef foo stroke:#f00
classDef bar stroke:#0f0
classDef ash color:red
class C ash
style C stroke:#00f, fill:black
AB["apa@apa@"] --> B(("`apa@apa`"))
</pre>
<pre id="diagram4" class="mermaid2">
flowchart
D(("for D"))
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
A e1@==> B
e1@{ animate: true}
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
A e1@--> B
classDef animate stroke-width:2,stroke-dasharray:10\,8,stroke-dashoffset:-180,animation: edge-animation-frame 6s linear infinite, stroke-linecap: round
class e1 animate
</pre>
<h2>infinite</h2>
<pre id="diagram4" class="mermaid2">
flowchart LR
A e1@--> B
classDef animate stroke-dasharray: 9\,5,stroke-dashoffset: 900,animation: dash 25s linear infinite;
class e1 animate
</pre>
<h2>Mermaid - edge-animation-slow</h2>
<pre id="diagram4" class="mermaid2">
flowchart LR
A e1@--> B
e1@{ animation: fast}
</pre>
<h2>Mermaid - edge-animation-fast</h2>
<pre id="diagram4" class="mermaid2">
flowchart LR
A e1@--> B
classDef animate stroke-dasharray: 1000,stroke-dashoffset: 1000,animation: dash 10s linear;
class e1 edge-animation-fast
</pre>
<pre id="diagram4" class="mermaid2">
stateDiagram
A:::foo
B:::bar --> C:::foobar
classDef foo stroke:#f00
classDef bar stroke:#0f0
style C stroke:#00f, fill:black, color:white
info </pre
>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
a
subgraph s0["APA"]
subgraph s8["APA"]
subgraph s1["APA"]
D{"X"}
E[Q]
end
subgraph s3["BAPA"]
F[Q]
I
end
D --> I
D --> I
D --> I
I{"X"}
end
end
</pre>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
a
D{"Use the editor"}
D -- Mermaid js --> I{"fa:fa-code Text"}
D-->I
D-->I
</pre>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
subgraph s1["Untitled subgraph"]
n1["Evaluate"]
n2["Option 1"]
n3["Option 2"]
n4["fa:fa-car Option 3"]
end
subgraph s2["Untitled subgraph"]
n5["Evaluate"]
n6["Option 1"]
n7["Option 2"]
n8["fa:fa-car Option 3"]
end
A["Start"] -- Some text --> B("Continue")
B --> C{"Evaluate"}
C -- One --> D["Option 1"]
C -- Two --> E["Option 2"]
C -- Three --> F["fa:fa-car Option 3"]
n1 -- One --> n2
n1 -- Two --> n3
n1 -- Three --> n4
n5 -- One --> n6
n5 -- Two --> n7
n5 -- Three --> n8
n1@{ shape: diam}
n2@{ shape: rect}
n3@{ shape: rect}
n4@{ shape: rect}
n5@{ shape: diam}
n6@{ shape: rect}
n7@{ shape: rect}
n8@{ shape: rect}
</pre>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
subgraph s1["Untitled subgraph"]
n1["Evaluate"]
n2["Option 1"]
end
n1 -- One --> n2
<pre id="diagram4" class="mermaid">
flowchart TB
A@{
label: "aksljhf kasjdh"
}
</pre>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
A{A} --> B & C
</pre
>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
A{A} --> B & C
subgraph "subbe"
A
end
</pre
>
<pre id="diagram4" class="mermaid2">
---
config:
layout: elk
---
flowchart LR
n2@{ shape: rect}
n3@{ shape: rect}
n4@{ shape: rect}
A["Start"] -- Some text --> B("Continue")
B --> C{"Evaluate"}
C -- One --> D["Option 1"]
C -- Two --> E["Option 2"]
C -- Three --> F["fa:fa-car Option 3"]
%% C@{ shape: hexagon}
</pre>
<pre id="diagram4" class="mermaid2">
---
config:
kanban:
ticketBaseUrl: 'https://github.com/your-repo/issues/#TICKET#'
---
kanban
Backlog
task1[📝 Define project requirements]@{ ticket: a101 }
To Do
task2[🔍 Research technologies]@{ ticket: a102 }
Review
task4[🔍 Code review for login feature]@{ ticket: a104 }
Done
task5[✅ Deploy initial version]@{ ticket: a105 }
In Progress
task3[💻 Develop login feature]@{ ticket: 103 }
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Default] --> A@{ icon: 'fa:bell', form: 'rounded' }
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Style] --> A@{ icon: 'fa:bell', form: 'rounded' }
style A fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Class] --> A@{ icon: 'fa:bell', form: 'rounded' }
A:::AClass
classDef AClass fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Class] --> A@{ icon: 'logos:aws', form: 'rounded' }
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Default] --> A@{ icon: 'fa:bell', form: 'square' }
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Style] --> A@{ icon: 'fa:bell', form: 'square' }
style A fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Class] --> A@{ icon: 'fa:bell', form: 'square' }
A:::AClass
classDef AClass fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Class] --> A@{ icon: 'logos:aws', form: 'square' }
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Default] --> A@{ icon: 'fa:bell', form: 'circle' }
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Style] --> A@{ icon: 'fa:bell', form: 'circle' }
style A fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Class] --> A@{ icon: 'fa:bell', form: 'circle' }
A:::AClass
classDef AClass fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Class] --> A@{ icon: 'logos:aws', form: 'circle' }
A:::AClass
classDef AClass fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
flowchart LR
nA[Style] --> A@{ icon: 'logos:aws', form: 'circle' }
style A fill:#f9f,stroke:#333,stroke-width:4px
</pre>
<pre id="diagram4" class="mermaid2">
kanban
id2[In progress]
docs[Create Blog about the new diagram]@{ priority: 'Very Low', ticket: MC-2037, assigned: 'knsv' }
</pre>
<pre id="diagram4" class="mermaid2">
---
config:
kanban:
ticketBaseUrl: 'https://mermaidchart.atlassian.net/browse/#TICKET#'
# sectionWidth: 300
---
kanban
Todo
[Create Documentation]
docs[Create Blog about the new diagram]
id7[In progress]
id6[Create renderer so that it works in all cases. We also add some extra text here for testing purposes. And some more just for the extra flare.]
id9[Ready for deploy]
id8[Design grammar]@{ assigned: 'knsv' }
id10[Ready for test]
id4[Create parsing tests]@{ ticket: MC-2038, assigned: 'K.Sveidqvist', priority: 'High' }
id66[last item]@{ priority: 'Very Low', assigned: 'knsv' }
id11[Done]
id5[define getData]
id2[Title of diagram is more than 100 chars when user duplicates diagram with 100 char]@{ ticket: MC-2036, priority: 'Very High'}
id3[Update DB function]@{ ticket: MC-2037, assigned: knsv, priority: 'High' }
id12[Can't reproduce]
id3[Weird flickering in Firefox]
</pre>
<script type="module">
import mermaid from './mermaid.esm.mjs';
import layouts from './mermaid-layout-elk.esm.mjs';
const staticBellIconPack = {
prefix: 'fa6-regular',
icons: {
bell: {
body: '<path fill="currentColor" d="M224 0c-17.7 0-32 14.3-32 32v19.2C119 66 64 130.6 64 208v25.4c0 45.4-15.5 89.5-43.8 124.9L5.3 377c-5.8 7.2-6.9 17.1-2.9 25.4S14.8 416 24 416h400c9.2 0 17.6-5.3 21.6-13.6s2.9-18.2-2.9-25.4l-14.9-18.6c-28.3-35.5-43.8-79.6-43.8-125V208c0-77.4-55-142-128-156.8V32c0-17.7-14.3-32-32-32m0 96c61.9 0 112 50.1 112 112v25.4c0 47.9 13.9 94.6 39.7 134.6H72.3c25.8-40 39.7-86.7 39.7-134.6V208c0-61.9 50.1-112 112-112m64 352H160c0 17 6.7 33.3 18.7 45.3S207 512 224 512s33.3-6.7 45.3-18.7S288 465 288 448"/>',
width: 448,
},
},
width: 512,
height: 512,
};
mermaid.registerIconPacks([
{
name: 'logos',
loader: () =>
fetch('https://unpkg.com/@iconify-json/logos@1/icons.json').then((res) => res.json()),
},
{
name: 'fa',
loader: () => staticBellIconPack,
},
]);
mermaid.registerLayoutLoaders(layouts);
mermaid.parseError = function (err, hash) {
console.error('Mermaid error: ', err);
@@ -437,8 +503,13 @@ flowchart TB
window.callback = function () {
alert('A callback was triggered');
};
mermaid.initialize({
// theme: 'base',
function callback() {
alert('It worked');
}
await mermaid.initialize({
// theme: 'forest',
// theme: 'default',
// theme: 'forest',
// handDrawnSeed: 12,
// look: 'handDrawn',
// 'elk.nodePlacement.strategy': 'NETWORK_SIMPLEX',
@@ -447,21 +518,21 @@ flowchart TB
// layout: 'fixed',
// htmlLabels: false,
flowchart: { titleTopMargin: 10 },
// fontFamily: 'Caveat',
// fontFamily: 'Kalam',
// fontFamily: 'courier',
fontFamily: "'Recursive', sans-serif",
sequence: {
actorFontFamily: 'courier',
noteFontFamily: 'courier',
messageFontFamily: 'courier',
},
kanban: {
htmlLabels: false,
},
fontSize: 12,
logLevel: 3,
logLevel: 0,
securityLevel: 'loose',
callback,
});
function callback() {
alert('It worked');
}
mermaid.parseError = function (err, hash) {
console.error('In parse error:');
console.error(err);

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css"
@@ -62,56 +62,23 @@
<body style="display: flex; gap: 2rem; flex-direction: row">
<pre id="diagram4" class="mermaid">
flowchart LR
A@{ icon: "fa:window-minimize", form: circle }
E@{ icon: "fa:window-minimize", form: circle }
B@{ icon: "fa:bell", form: circle }
B2@{ icon: "fa:bell", form: circle }
C@{ icon: "fa:address-book", form: square }
D@{ icon: "fa:star-half", form: square }
A --> E
B --> B2
flowchart
A --> A
subgraph B
B1 --> B1
end
subgraph C
subgraph C1
C2 --> C2
subgraph D
D1 --> D1
end
D --> D
end
C1 --> C1
end
</pre>
<pre id="diagram4" class="mermaid2">
flowchart TB
A --test2--> B2@{ icon: "fa:bell", form: "rounded", label: "B2 aiduaid uyawduad uaduabd uyduadb", pos: "b" }
B2 --test--> C
D --> B2 --> E
style B2 fill:#f9f,stroke:#333,stroke-width:4px
</pre
>
<pre id="diagram43" class="mermaid2">
flowchart BT
A --test2--> B2@{ icon: "fa:bell", form: "square", label: "B2", pos: "t", h: 40, w: 30 }
B2 --test--> C
D --> B2 --> E
</pre
>
<pre id="diagram4" class="mermaid2">
flowchart BT
A --test2--> B2@{ icon: "fa:bell", label: "B2 awiugdawu uydgayuiwd wuydguy", pos: "b", h: 40, w: 30 }
B2 --test--> C
</pre
>
<pre id="diagram43" class="mermaid2">
flowchart BT
A --test2--> B2@{ icon: "fa:bell", label: "B2 dawuygd ayuwgd uy", pos: "t", h: 40, w: 30 }
B2 --test--> C
</pre
>
<pre id="diagram6" class="mermaid2">
flowchart TB
A --> B2@{ icon: "fa:bell", form: "circle", label: "test augfuyfavf ydvaubfuac", pos: "t", w: 200, h: 100 } --> C
</pre
>
<pre id="diagram6" class="mermaid2">
flowchart TB
A --> B2@{ icon: "fa:bell", form: "circle", label: "test augfuyfavf ydvaubfuac", pos: "b", w: 200, h: 100 } --> C
D --> B2 --> E
</pre
>
<script type="module">
import mermaid from './mermaid.esm.mjs';
import layouts from './mermaid-layout-elk.esm.mjs';

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -3,7 +3,7 @@
<head>
<link href="https://fonts.googleapis.com/css?family=Montserrat&display=swap" rel="stylesheet" />
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css" />
<link href="https://cdn.jsdelivr.net/npm/@mdi/font@6.9.96/css/materialdesignicons.min.css" rel="stylesheet" />
<link href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap" rel="stylesheet" />
<link rel="preconnect" href="https://fonts.googleapis.com" />

File diff suppressed because one or more lines are too long

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

View File

@@ -4,7 +4,7 @@
<link href="https://unpkg.com/tailwindcss@^1.0/dist/tailwind.min.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.2/css/font-awesome.min.css"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/font-awesome.min.css"
/>
<link
href="https://fonts.googleapis.com/css?family=Noto+Sans+SC&display=swap"

Some files were not shown because too many files have changed in this diff Show More