Commit Graph

6018 Commits

Author SHA1 Message Date
Sidharth Vinod 649ab17806
feat: Add config validator MVP 2022-11-09 09:54:52 +05:30
Sidharth Vinod c7f7ff39ce
fix: Import path in viewer.js 2022-11-09 00:43:19 +05:30
Sidharth Vinod 8e63a072e4
Cleanup package.json 2022-11-09 00:39:54 +05:30
Sidharth Vinod b03ac389fa
Restore package and lock from master 2022-11-09 00:36:38 +05:30
Sidharth Vinod d2511f6a8c
fix pnpm lock 2022-11-08 20:21:37 +05:30
Sidharth Vinod 5b53cee673
Fix pnpm-lock 2022-11-08 20:16:17 +05:30
Sidharth Vinod 1b2dce99c9
Merge branch 'release/9.2.1' of https://github.com/mermaid-js/mermaid into sidv/fixLL
* 'release/9.2.1' of https://github.com/mermaid-js/mermaid:
  Fixing applitools batches
2022-11-08 20:15:13 +05:30
Knut Sveidqvist ba7f83019f Fixing applitools batches 2022-11-08 15:25:05 +01:00
Sidharth Vinod 745abb81dc
Fix pnpm 2022-11-08 19:52:24 +05:30
Sidharth Vinod e64e98fbfc
Bump pnpm 2022-11-08 19:48:26 +05:30
Sidharth Vinod 605f288554
fix Lint 2022-11-08 19:33:50 +05:30
Sidharth Vinod 6d2552ea6e
fix: Filenames 2022-11-08 19:26:02 +05:30
Sidharth Vinod 20b4358c0e
fix: Make options in registerExternalDiagrams optional 2022-11-08 19:21:49 +05:30
Sidharth Vinod 7ca525622b
fix #3757 : Remove dynamic imports for lazy load. 2022-11-08 19:12:37 +05:30
Sidharth Vinod aab8f9273f
Merge branch 'feat/3701-expose-registerDiagram' into sidv/fixLL
* feat/3701-expose-registerDiagram:
  feat: add `mermaidAPI.registerDiagram()`
  refactor(mermaid): remove registerDiagram cb func
  fix(mermaid): fix DiagramDefinition types
2022-11-08 13:50:54 +05:30
Sidharth Vinod 166dca4924
webpack test 2022-11-08 12:51:59 +05:30
Sidharth Vinod 75d276e19e
Merge branch 'release_9.2.1_bugfixes' into sidv/webpackTest
* release_9.2.1_bugfixes:
  fix(mermaid): default mermaid back to CommonJS
  fix(mermaid): fix mermaid.render types
2022-11-07 14:32:35 +05:30
Sidharth Vinod 2243af1871
Merge pull request #3767 from aloisklink/fix/convert-package-back-to-commonjs
[9.2] fix(mermaid): default mermaid back to CommonJS
2022-11-07 14:31:45 +05:30
Sidharth Vinod 41dbf0fa96
Merge pull request #3768 from aloisklink/fix/fix-mermaid.render-types
[9.2] fix(mermaid): fix `mermaid.render` types
2022-11-07 14:01:37 +05:30
Alois Klink 1a5e7315c0 fix(mermaid): default mermaid back to CommonJS
Default mermaid back to being a CommonJS module.

Improrting Mermaid as CommonJS (e.g. using `require("mermaid")`)
is normally broken (since v8), due to it's dependency on d3,
which is now ESM only.

However, it looks like some software
(e.g. TypeScript, in the docusaurus project)
could still handle the CommonJS version of Mermaid.

This commit now means that older versions of Node/build-tools
should now default to using the CommonJS version of Mermaid.

Newer tools should still see that the `"module"` field points to ESM,
or use the `exports["."]["import"]` field to load ESM.
2022-11-06 23:41:09 +00:00
Alois Klink da6bb9498a fix(mermaid): fix mermaid.render types
The cb param of mermaid.render should be optional,
and mermaid.render returns an SVG string instead of `void`.
2022-11-06 22:46:57 +00:00
Sidharth Vinod 1e417833f4
Basic webpack 2022-11-04 11:29:24 +05:30
Sidharth Vinod 97a7f1fd71
Merge pull request #2739 from Andre601/feature/issue-templates
Use issue templates and add diagram, theme and syntax proposal issue forms
2022-11-03 11:07:00 +05:30
Sidharth Vinod c86d46eb8a
Add Security Policy 2022-11-03 11:06:21 +05:30
Sidharth Vinod 361dd6a96e
Add Security Policy 2022-11-03 10:59:57 +05:30
Sidharth Vinod 17adec38af
chore: lint 2022-11-03 10:59:56 +05:30
Andre_601 638b9d9aae
Discussions are now available 2022-11-03 10:59:56 +05:30
Andre_601 c8f6994895
Make colors required 2022-11-03 10:59:55 +05:30
Andre_601 1117a80500
make setup not required 2022-11-03 10:59:55 +05:30
Andre_601 5d83ec6fa2
Update theme_proposal.yml 2022-11-03 10:59:54 +05:30
Andre_601 bab5937426
Update syntaxt_proposal.yml 2022-11-03 10:59:54 +05:30
Andre_601 099a26977a
Update diagram_proposal.yml 2022-11-03 10:59:53 +05:30
Andre_601 0b834485a8
Update bug_report.yml 2022-11-03 10:59:52 +05:30
Andre_601 41f21d4f72
Delete question.md 2022-11-03 10:59:50 +05:30
Andre_601 312e5f3d96
Create syntaxt_proposal.yml 2022-11-03 10:59:35 +05:30
Andre_601 6ef3e7f536
Create theme_proposal.yml 2022-11-03 10:59:34 +05:30
Andre_601 4f5228aec4
Create diagram_proposal.yml 2022-11-03 10:59:32 +05:30
Andre_601 b9daa35558
Switch to bug_report.yml 2022-11-03 10:59:10 +05:30
Andre_601 21304a9677
Create config.yml 2022-11-03 10:57:57 +05:30
Knut Sveidqvist 3f6613ea9f Updated mermaid version for the docs 2022-11-01 15:52:35 +01:00
Knut Sveidqvist c8635c0b9b Merge branch 'release/9.2.0'
Conflicts:
	.github/ISSUE_TEMPLATE/bug_report.md
2022-11-01 15:37:00 +01:00
Knut Sveidqvist e78ac9b92a Updated version 2022-11-01 15:27:20 +01:00
Sidharth Vinod 7a47fcfcbc
Merge pull request #3727 from gibson042/2022-10-issue-template
chore: Update bug report template
2022-10-29 23:44:02 +05:30
Knut Sveidqvist d4c19ffa59 Merge branch 'release/9.2.0' of github.com:mermaid-js/mermaid into release/9.2.0 2022-10-28 09:34:36 +02:00
Knut Sveidqvist 120940f9f4
Merge pull request #3731 from aloisklink/fix/load-lazy-loaded-diagrams-in-initThrowsErrors
[9.2.0] Support `lazyLoadedDiagrams` when calling `initThrowsErrorsAsync`
2022-10-28 09:33:58 +02:00
Alois Klink 48b1f489fc fix(mermaid): error if lazyLoadedDiagrams fails
Throws and logs a warning if lazyLoadedDiagrams fails to load properly.

Rendering is still performed, even on a lazyLoadedDiagrams failure.
2022-10-27 17:48:21 +01:00
Alois Klink e62dd255bc feat: expose initThrowsErrorsAsync publicly
Expose the function `initThrowsErrorsAsync()` publicly
as `mermaid.initThrowsErrorsAsync()`.

It has the TSDoc `@alpha` and `@deprecated` tags, so people should
be warned that it might be modified in Mermaid v10 or earlier.

Needed for `mermaid-cli` to handle `lazyLoadedDiagrams`.
2022-10-27 17:48:12 +01:00
Alois Klink 13110c4ed9 docs(mermaid): document initThrowsErrorsAsync
Add some basic tsdoc for initThrowsErrorsAsync.
2022-10-27 17:02:50 +01:00
Alois Klink 327fcbf902 fix: lazy load diagrams in initThrowsErrorsAsync
Previously, calling initThrowsErrorsAsync would not
load any of the lazyLoadedDiagrams entries.

Adaptated from reverted commit 4601c90904
2022-10-27 16:50:57 +01:00
Alois Klink 81924f72c8 Revert "Merge branch 'release_9.2.0_buggfixes'"
This reverts commit 1a0309fb87, reversing
changes made to 56a8068a7f.

This is because the PR https://github.com/mermaid-js/mermaid/pull/3702
worked fine on the `develop` and `release_9.2.0_buggfixes` branches,
but had a bunch of git merge conflicts on the `release/9.2.0` branch.
2022-10-27 16:43:09 +01:00