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

fix(docs): render Mermaid diagrams in docs #12464

Merged
merged 1 commit into from
Jan 4, 2024

Conversation

agilgur5
Copy link
Member

@agilgur5 agilgur5 commented Jan 4, 2024

Motivation

  • docs/retries.md has a Mermaid diagram that renders out-of-the-box on GH but not on the docs site itself
    • needs a Mermaid renderer for mkdocs

follow-up to #11005, #11390 (comment), and Nov 21st Contributor Meeting

Modifications

Verification

Ran make docs followed by open site/retries/index.html to view in the browser.

Screenshots:

Before:
Screenshot 2024-01-04 at 3 03 00 PM

After:
Screenshot 2024-01-04 at 2 34 36 PM

- `docs/retries.md` has a Mermaid diagram that renders out-of-the-box on GH but not on the docs site itself
  - add a `pymdownx.superfences` config to render out Mermaid diagrams in `mkdocs` per https://squidfunk.github.io/mkdocs-material/reference/diagrams/#configuration

follow-up to 310bb5a

Signed-off-by: Anton Gilgur <agilgur5@gmail.com>
@agilgur5 agilgur5 added area/docs Incorrect, missing, or mistakes in docs area/build Build or GithubAction/CI issues labels Jan 4, 2024
Copy link
Member

@terrytangyuan terrytangyuan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am curious - is this reactive? Can you try resizing your browser?

@agilgur5
Copy link
Member Author

agilgur5 commented Jan 4, 2024

I am curious - is this reactive? Can you try resizing your browser?

I think you mean responsive. Technically speaking, yes, it's a percentage of the screen:

Screenshot 2024-01-04 at 3 51 59 PM

That's a variant of responsive design (it used to be called adaptive design back in the day (~2014), but that now means something different). In full responsive design, you may want to render a different image for different screen sizes.

GitHub has the fancy controls and mouse gestures that let you zoom and scroll the diagram which this does not. Those are nice, but I think this is good enough. Users can click the image to see it full screen if they want to and then zoom from there etc

@terrytangyuan
Copy link
Member

Great thanks! Yes I meant responsive.

@terrytangyuan terrytangyuan merged commit 1968436 into argoproj:main Jan 4, 2024
16 checks passed
@agilgur5 agilgur5 deleted the fix-docs-mermaid-render branch January 4, 2024 21:06
@agilgur5
Copy link
Member Author

agilgur5 commented Jan 4, 2024

Rendering properly on RTD now 🙂 : https://argo-workflows.readthedocs.io/en/latest/retries/#retry-policies

jmeridth added a commit to jmeridth/argo-workflows that referenced this pull request Jan 5, 2024
Includes fixes from argoproj#12464, argoproj#12466, argoproj#12465 - all authored by @agilgur5

Includes files list from argoproj#12414 description

Signed-off-by: jmeridth <jmeridth@gmail.com>
Co-authored-by: Anton Gilgur <agilgur5@gmail.com>
jmeridth added a commit to jmeridth/argo-workflows that referenced this pull request Jan 5, 2024
Includes fixes from argoproj#12464, argoproj#12466, argoproj#12465 - all authored by @agilgur5

Includes files list from argoproj#12414 description

Signed-off-by: jmeridth <jmeridth@gmail.com>
Co-authored-by: Anton Gilgur <agilgur5@gmail.com>
jmeridth added a commit to jmeridth/argo-workflows that referenced this pull request Jan 5, 2024
Includes fixes from argoproj#12464, argoproj#12466, argoproj#12465 - all authored by @agilgur5

Includes files list from argoproj#12414 description

Signed-off-by: jmeridth <jmeridth@gmail.com>
Co-authored-by: Anton Gilgur <agilgur5@gmail.com>
isubasinghe pushed a commit to isubasinghe/argo-workflows that referenced this pull request Feb 27, 2024
isubasinghe pushed a commit to isubasinghe/argo-workflows that referenced this pull request Feb 27, 2024
isubasinghe pushed a commit to isubasinghe/argo-workflows that referenced this pull request Feb 27, 2024
isubasinghe pushed a commit to isubasinghe/argo-workflows that referenced this pull request Feb 28, 2024
Signed-off-by: Isitha Subasinghe <isubasinghe@student.unimelb.edu.au>
isubasinghe pushed a commit to isubasinghe/argo-workflows that referenced this pull request Mar 12, 2024
@agilgur5 agilgur5 added this to the v3.5.x patches milestone Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/build Build or GithubAction/CI issues area/docs Incorrect, missing, or mistakes in docs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants