markdown_convert 1.2.25__py3-none-any.whl → 1.2.27__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -221,3 +221,9 @@ math {
221
221
  text-rendering: optimizeLegibility;
222
222
  font-family: "Latin Modern Math", "Cambria Math", serif;
223
223
  }
224
+
225
+ /* Mermaid diagrams */
226
+ div.mermaid {
227
+ display: flex;
228
+ justify-content: center;
229
+ }
@@ -53,13 +53,19 @@ def render_mermaid_diagrams(html, *, nonce):
53
53
 
54
54
  Args:
55
55
  html (str): HTML content.
56
+ nonce (str): Cryptographic nonce for CSP.
56
57
  Returns:
57
58
  str: HTML content with rendered Mermaid diagrams.
58
59
  """
59
60
  mermaid_script = f"""
60
61
  <script type="module" nonce="{nonce}">
61
- import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.esm.min.mjs';
62
- mermaid.initialize({{ startOnLoad: true }});
62
+ import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@11/dist/mermaid.esm.min.mjs';
63
+ mermaid.initialize({{
64
+ startOnLoad: true,
65
+ theme: 'default',
66
+ themeVariables: {{}},
67
+ fontFamily: 'arial, verdana, sans-serif'
68
+ }});
63
69
  </script>
64
70
  """
65
71
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: markdown_convert
3
- Version: 1.2.25
3
+ Version: 1.2.27
4
4
  Summary: Convert Markdown files to PDF from your command line.
5
5
  Project-URL: homepage, https://github.com/Julynx/markdown_convert
6
6
  Author-email: Julio Cabria <juliocabria@tutanota.com>
@@ -50,6 +50,7 @@ Unlike other similar tools, `markdown-convert`:
50
50
  - Comes with a sensible default CSS stylesheet out of the box.
51
51
  - Supports:
52
52
  - **LaTeX math equations:** `$...$` for inline and `$$...$$` for block equations.
53
+ - **Mermaid diagrams:** ` ```mermaid ...``` ` code blocks get rendered as diagrams.
53
54
  - **Syntax highlighting for code blocks:** Applied automatically based on the specified language.
54
55
  - **Live conversion:** `markdown-convert file.md --mode=live` updates the PDF every time the Markdown file changes.
55
56
  - **Custom CSS** `markdown-convert file.md --css=style.css` extends the default CSS with your own stylesheet.
@@ -1,16 +1,16 @@
1
1
  markdown_convert/__init__.py,sha256=ysW3pXsDGGK4PzZHcIBTpfVW58IkDUwHffDkf_GM6UU,303
2
2
  markdown_convert/__main__.py,sha256=hO7AO0GnzPMPNqls8r5aF2C-7l9aFHDf1m8mXSy1GBE,2809
3
3
  markdown_convert/code.css,sha256=Wt4FqFqJcpT-jwY3GN-o4ZRCCXU8DQj-9lqKdGiuoyw,4935
4
- markdown_convert/default.css,sha256=sTIJmfRWOe8SVwlhzw9CSXD44TUtgfjKCHJjf6u2O8U,2877
4
+ markdown_convert/default.css,sha256=ycMjgZXTjuD8fsQGHDtSRUBdWk_bMpehz_-bvGhyKhA,2965
5
5
  markdown_convert/modules/__init__.py,sha256=PFPgiQhMXgyfjD8BkfLC_X8AR1jz-dCxfif2qmNofJs,65
6
6
  markdown_convert/modules/constants.py,sha256=3pHREdede6XhR-Jlp_SSm1hg0CtJNApdL-T7Rs-G_Bk,475
7
7
  markdown_convert/modules/convert.py,sha256=a3WfnWxATHqqLsMG3WUYmfdGIF3-ZFifUqDCM044WV4,9725
8
8
  markdown_convert/modules/resources.py,sha256=tnW8JmCrJNBRbzOcaOVG6GX5jPC8Kzj3dA7gX0B935A,2488
9
- markdown_convert/modules/transform.py,sha256=Z_htEa4D9xoFJwoXl-ik8UXumfkc14wQrTcIC6QQ2dw,1756
9
+ markdown_convert/modules/transform.py,sha256=NEjrPOR9yA8sxnh1kDWbVfBrDmkUMnBn2_Shmdi0bIE,1906
10
10
  markdown_convert/modules/utils.py,sha256=NX0WegM8e8MPKNNmweTujAWO8ZghdB8LSGDx20K2E44,655
11
11
  markdown_convert/modules/validate.py,sha256=XV_k7cHeifEKDaltF26tCmabs2-Me5msP3enI_eVwfA,1517
12
- markdown_convert-1.2.25.dist-info/METADATA,sha256=BDZfDpKYUFsy3ixIDtvYprzVB_xZBoruLAJ48yptx8w,3797
13
- markdown_convert-1.2.25.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
14
- markdown_convert-1.2.25.dist-info/entry_points.txt,sha256=RCmzC7C0sX-SpzIP2Cr34rhg3lMd7BRx-exaZPfK8bU,68
15
- markdown_convert-1.2.25.dist-info/licenses/LICENSE,sha256=gXf5dRMhNSbfLPYYTY_5hsZ1r7UU1OaKQEAQUhuIBkM,18092
16
- markdown_convert-1.2.25.dist-info/RECORD,,
12
+ markdown_convert-1.2.27.dist-info/METADATA,sha256=dXCy9bq8Xwo8Yy7gyIank7BcwV3Em9-IpmQS--2BqaU,3883
13
+ markdown_convert-1.2.27.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
14
+ markdown_convert-1.2.27.dist-info/entry_points.txt,sha256=RCmzC7C0sX-SpzIP2Cr34rhg3lMd7BRx-exaZPfK8bU,68
15
+ markdown_convert-1.2.27.dist-info/licenses/LICENSE,sha256=gXf5dRMhNSbfLPYYTY_5hsZ1r7UU1OaKQEAQUhuIBkM,18092
16
+ markdown_convert-1.2.27.dist-info/RECORD,,