Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for #2509 #4740

Conversation

jason-curtis
Copy link
Contributor

📑 Summary

Since #2509 is unlikely to be solved soon I'm adding some documentation. This should at least make the behavior less surprising.

I don't think it actually resolves #2509 but since this is expected behavior per @knsv (here) maybe #2509 can be recategorized as a feature request.

📏 Design Decisions

Nothing surprising here. I included an illustrative example.

📋 Tasks

Make sure you

  • 📖 have read the contribution guidelines
  • 💻 have added necessary unit/e2e tests.
    • (N/A - documentation only)
  • 📓 have added documentation. Make sure MERMAID_RELEASE_VERSION is used for all new features.
  • 🔖 targeted develop branch

@codecov
Copy link

codecov bot commented Aug 16, 2023

Codecov Report

Merging #4740 (edb6cea) into develop (99978da) will not change coverage.
The diff coverage is n/a.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           develop    #4740   +/-   ##
========================================
  Coverage    77.18%   77.18%           
========================================
  Files          145      145           
  Lines        14659    14659           
  Branches       586      586           
========================================
  Hits         11315    11315           
  Misses        3233     3233           
  Partials       111      111           
Flag Coverage Δ
e2e 83.90% <ø> (ø)
unit 46.10% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@sidharthv96
Copy link
Member

@jason-curtis can you run prettier to fix the formatting issues?

https://mermaid.js.org/community/development.html#contributing-documentation

@jason-curtis
Copy link
Contributor Author

jason-curtis commented Aug 17, 2023

@sidharthv96 It's hard to see how these lint errors could be from my change. I don't see any mention of prettier in the documentation you sent, so maybe something is missing?

I'll try running prettier and see what happens.

@sidharthv96
Copy link
Member

Prettier is run automatically when you commit locally, once you have run pnpm install.
Committing locally would also build the docs and inject that into the PR.

@jason-curtis
Copy link
Contributor Author

jason-curtis commented Aug 17, 2023

ah I see the prettier issue now. I didn't see the [warn] packages/mermaid/src/docs/syntax/flowchart.md amidst all of the yellow eslint warnings!

I've been trying to get everything to install and build cleanly on a fresh GH codespace, no luck so far.

curl https://get.volta.sh | bash
# (restart terminal here)
volta install node
npx pnpm install # and then you have to tell it yes, install pnpm
# ^ this command fails.

Here's a full gist of the 2nd terminal session: https://gist.github.com/jason-curtis/746affa2385639c8fd2ea3c0332c70e3
It looks like the error is:

packages/mermaid/src/setupGraphViewbox.js (2:9) "SVG" is not exported by "packages/mermaid/src/diagram-api/types.ts", imported by "packages/mermaid/src/setupGraphViewbox.js".

At this point the package is at least partially installed, so I may be able to bash through by manually running prettier (already did this in #ef8b75a ) and the docs build (I'll try this next).

@jason-curtis
Copy link
Contributor Author

jason-curtis commented Aug 17, 2023

OK, I was able to manually run npx pnpm --filter mermaid run docs:build as suggested in the latest failed job so hopefully that'll cover it.

It looks like things are pretty OK in my latest codespace despite the error when running npx pnpm install - I guess it came close enough to completing the install properly.

Thanks for your guidance.

@sidharthv96
Copy link
Member

@jason-curtis thank you! I'll fix the SVG error.

@sidharthv96 sidharthv96 added this pull request to the merge queue Aug 17, 2023
@sidharthv96
Copy link
Member

Yeah, the final step of install is the build, which failed due to the SVG bug.
But prettier and docs don't really need that.

Merged via the queue into mermaid-js:develop with commit 7b7e281 Aug 17, 2023
13 checks passed
@mermaid-bot
Copy link

mermaid-bot bot commented Aug 17, 2023

@jason-curtis, Thank you for the contribution!
You are now eligible for a year of Premium account on MermaidChart.
Sign up with your GitHub account to activate.

fuxingloh pushed a commit to fuxingloh/contented that referenced this pull request Aug 28, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [mermaid](https://togithub.com/mermaid-js/mermaid) | [`10.3.1` ->
`10.4.0`](https://renovatebot.com/diffs/npm/mermaid/10.3.1/10.4.0) |
[![age](https://developer.mend.io/api/mc/badges/age/npm/mermaid/10.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/mermaid/10.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/mermaid/10.3.1/10.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/mermaid/10.3.1/10.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>mermaid-js/mermaid (mermaid)</summary>

###
[`v10.4.0`](https://togithub.com/mermaid-js/mermaid/releases/tag/v10.4.0)

[Compare
Source](https://togithub.com/mermaid-js/mermaid/compare/v10.3.1...v10.4.0)

#### Features

- feat: Support config in frontmatter. by
[@&#8203;sidharthv96](https://togithub.com/sidharthv96) in
[mermaid-js/mermaid#4750
- feat(sankey): Show values by
[@&#8203;sidharthv96](https://togithub.com/sidharthv96) in
[mermaid-js/mermaid#4748

#### Docs

- docs: Add development example page. by
[@&#8203;sidharthv96](https://togithub.com/sidharthv96) in
[mermaid-js/mermaid#4714
- Documentation for
[#&#8203;2509](https://togithub.com/mermaid-js/mermaid/issues/2509) by
[@&#8203;jason-curtis](https://togithub.com/jason-curtis) in
[mermaid-js/mermaid#4740
- Fixes to Docs sidebar, main page and badges by
[@&#8203;nirname](https://togithub.com/nirname) in
[mermaid-js/mermaid#4742
- Split development documentation into several pages by
[@&#8203;nirname](https://togithub.com/nirname) in
[mermaid-js/mermaid#4744
- Docs: update Latest News section by
[@&#8203;huynhicode](https://togithub.com/huynhicode) in
[mermaid-js/mermaid#4768

#### Chores

- Update all minor dependencies (minor) by
[@&#8203;renovate](https://togithub.com/renovate) in
[mermaid-js/mermaid#4732
- Update all patch dependencies (patch) by
[@&#8203;renovate](https://togithub.com/renovate) in
[mermaid-js/mermaid#4731
- convert `assignWithDepth` to TS by
[@&#8203;Yokozuna59](https://togithub.com/Yokozuna59) in
[mermaid-js/mermaid#4717
- convert `diagrams/common/svgDrawCommon.js` to ts by
[@&#8203;Yokozuna59](https://togithub.com/Yokozuna59) in
[mermaid-js/mermaid#4724
- ci(release-drafter): add more release notes categories by
[@&#8203;aloisklink](https://togithub.com/aloisklink) in
[mermaid-js/mermaid#4752
- chore(deps): update all patch dependencies (patch) by
[@&#8203;renovate](https://togithub.com/renovate) in
[mermaid-js/mermaid#4753
- standardized pie definitions by
[@&#8203;Yokozuna59](https://togithub.com/Yokozuna59) in
[mermaid-js/mermaid#4501
- Remove Circular Dependencies by
[@&#8203;sidharthv96](https://togithub.com/sidharthv96) in
[mermaid-js/mermaid#4761
- chore: Enforce type imports by
[@&#8203;sidharthv96](https://togithub.com/sidharthv96) in
[mermaid-js/mermaid#4763
- chore: Preview PRs with mermaid-live-editor on Netlify by
[@&#8203;sidharthv96](https://togithub.com/sidharthv96) in
[mermaid-js/mermaid#4769

#### New Contributors

- [@&#8203;jason-curtis](https://togithub.com/jason-curtis) made their
first contribution in
[mermaid-js/mermaid#4740

**Full Changelog**:
mermaid-js/mermaid@v10.3.1...v10.4.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/levaintech/contented).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi41Ni4wIiwidXBkYXRlZEluVmVyIjoiMzYuNTYuMCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

subgraph direction not applying
3 participants