Author: bowenliang123
Github Repository: https://github.com/bowenliang123/md_exporter
Dify Marketplace: https://marketplace.dify.ai/plugins/bowenliang123/md_exporter
This Dify plugin md_exporter
provides tools to export Markdown text to DOCX, PPTX, XLSX, PDF, HTML, MD, CSV, JSON, XML, LaTex, RST files, and extract code blocks to snippet files as .py
, .sh
, .js
, .xml
file, and etc.
Tool |
Input
(Syntax) |
Output |
---|---|---|
md_to_docx |
Markdown text | Word file (.docx) |
md_to_html |
HTML file (.html) | |
md_to_html_text |
HTML text | |
md_to_pdf |
PDF file (.pdf) | |
md_to_png |
PNG image (.png) of generated PDF pages.
Or a ZIP file of image files.
|
|
md_to_md |
Markdown file (.md) | |
md_to_xml |
XML file (.xml) | |
md_to_pptx |
Markdown slides
with md2pptx style
|
PowerPoint file (.pptx) |
md_to_codeblock |
in Markdown text
|
Generating files by language:
Or a ZIP file of codeblock files.
|
md_to_linked_image |
in Markdown text
|
Images files from the linked image URLs.
Only http or https URLs are supported.
|
md_to_xlsx |
Markdown tables | Excel file (.xlsx) |
md_to_csv |
CSV file (.csv) | |
md_to_json |
JSON file (.json), in style of
|
|
md_to_latex |
LaTeX file (.tex) |
Custom styling: Template DOCX file
md_to_docx
tool supports using an optional custom DOCX template file. The default template docx file used inmd_to_docx
tool could be fond in this link.In Microsoft Word, the template docx file controls the styles for headings, paragraphs, tables, lists, etc.
Please refer to Microsoft Words's official docs at
Modify an existing style
section of Customize or create new styles. Use Microsoft Word's "Home" - "Style Panel" to set the fonts, font size, color, spacing, indentation, alignment, etc.
Input Markdown text:
| Name | Age | City |
|---------|-----|-------------|
| Alice | 30 | New York |
| Bowen | 25 | Guangzhou |
| Charlie | 35 | Tokyo |
| David | 40 | Miami |
output XLSX file:
Syntax
The input Markdown text of slides MUST follows the syle rules of md2pptx's syntax. It supports:
- Title Slides
- Bullet Items
- Tables
- Hyper links and Inner links
- and more, please refer to docs.
Custom styling by Template PPTX file: Slide Master
md_to_pptx
tool supports using an optional custom PPTX template file with slide master. The default template pptx file used inmd_to_pptx
tool could be fond in this link.In Microsoft PowerPoint, a slide master controls the overall design and layout of the slides in a presentation, eg. font size on title, color style for text, layouts.
If you are looking for a way to customize the appearance of your slides, you can create a template PPTX file with slide master.
To update the slide master of template pptx file, please refer to Microsoft's official docs at Customize a slide master.
As with the input Markdown text in md2pptx sytle below:
# Markdown Exporter
### Slide 1 Title
* One
* One A
* One B
* Two
* Two X
* Two Y
### Slide 2 Title
|Left Heading|Centre Heading|Right Heading|
|:---|:-:|--:|
|Alpha|Bravo|1|
|Charlie|Delta|2|
The output PPTX file:
Multiple generated files in formats by language type of the extracted code blocks:
- python → .py file
- javascript → .js file
- html → .html file
- bash → .sh file
- json → .json file
- xml → .xml file
- svg → .svg file
- css → .css file
- yaml → .yaml file
- ruby → .rb file
- java → .java file
- php → .php file
- markdown → .md file
If compression is enabled, all the code blocks will be generated into a single ZIP file.
Converted .rst file by using mistune's RST render with basic reStructedText syntax support.
-
JSONL style (default output style)
-
JSON Array style
output LaTeX file:
viewed as PDF:
Output .md
file with orginal input Markdown text.
-
2.0.0:
- [ BREAKING CHANGE ] migrate
md_to_docx
tool to usepandoc
for conversion - Major improvements in
md_to_docx
tool- support custom styling by using a template DOCX file, setting the fonts, font size, color style for headings, paragraphs, etc.
- optimized file size in generated docx file
- better support for multi-language content
- remove
md_to_rst
andmd_to_epub
tools - add
force_text_value
option in md_to_xlsx tool to control whether to force convert all cell values to text string
- [ BREAKING CHANGE ] migrate
-
1.12.0:
- fix input pptx template file optional in
md_to_pptx
tool - fix error message with file path in cmd assembly in
md_to_pptx
tool - bump
md2pptx
to 6.0
- fix input pptx template file optional in
-
1.10.2:
- bump
md2pptx
from 5.4.4 to 5.4.5 - bump
python-docx
from 1.1 to 1.2.0 - increase PDF generation capacity limit to 500MB
- bump
-
1.10.0:
- Support output JSONL style in
md_to_json
tool, as JSON Lines format with one object per line - Change the default output style of
md_to_json
tool to JSONL - Minor doc updates in parameter description
- Support output JSONL style in
-
1.9.0:
- Support custom sheet name in
md_to_xlsx
tool by using headings in Markdown text - Force convert column type to string in
md_to_xlsx
tool to prevent data precision loss and display issues in Microsoft Excel - Autofit column width in
md_to_xlsx
tool
- Support custom sheet name in
-
1.8.0:
- Solve issues with garbled characters when opening CSV files containing non-ASCII characters (eg. Chinese or Japanese characters, Emoji characters etc.) in Microsoft Excel
-
1.7.0:
- Support custom PPTX template file in
md_to_pptx
tool - Support file generation from multiple tables in md_to_csv, md_to_latex, md_to_xlsx tools
- Support custom PPTX template file in
-
1.6.0:
- Introducing
md_to_html_text
tool, support converting Markdown text to HTML text - Standardize fonts for headings and body paragraphs DOCX file generated by
md_to_docx
tool
- Introducing
-
1.5.0:
- Improve PDF display for pure English markdown text input in
md_to_pdf
tool, by skipping the font setting for CJK characters - Introduce
md_to_epub
tool, support converting Markdown text to EPUB eBook files - Support compressing all png files in single zip file in
md_to_png
tool - Increase capacity limit for PDF file to 100MB in
md_to_pdf
tool - Remove explicit timeout config MAX_REQUEST_TIMEOUT
- Improve PDF display for pure English markdown text input in
-
1.4.100:
- Special version for celebrating Dify's 100k GitHub stars milestone
- add
md_to_png
tool, support converting Markdown text to PNG image files
-
1.3.0:
- update SDK version
-
1.2.0:
- Support compressing images to single zip file in
md_to_linked_image
tool
- Support compressing images to single zip file in
-
1.1.0:
- Enable line breaks normalization in all tools by default, replacing all the occurrences of
\\n
to\n
- Remove
<think>
tags of reasoning content in the input Markdown text - Fix missing custom output filename support in md_to_csv, md_to_json, md_to_latex tool
- Enable line breaks normalization in all tools by default, replacing all the occurrences of
-
1.0.1:
- Remove redundant URL safe conversion in custom output filename
-
1.0.0:
- Support customize the output file name
-
0.5.0:
- Introducing
md_to_linked_image
tool, support extracting image files in links in Markdown text
- Introducing
-
0.4.3:
- improve the display of Chinese characters in text paragraph in
md_to_docx
tool, by setting global font to Song if content contains Chinese - improve the display of Chinese characters in text paragraph inmd_to_docx
tool, by setting global font to Song if content contains Chinese charactor
- improve the display of Chinese characters in text paragraph in
-
0.4.2:
- support Java, PHP and Ruby file exporting in
md_to_codeblocks
tool
- support Java, PHP and Ruby file exporting in
-
0.4.1:
- support YAML file exporting in
md_to_codeblocks
tool
- support YAML file exporting in
-
0.4.0:
- support exporting Markdown codeblocks in to single zip file in
md_to_codeblocks
tool
- support exporting Markdown codeblocks in to single zip file in
-
0.3.0:
- Fixed the error in importing libraries of
md_to_pptx
tool when running on self-hosted Dify plugin-daemon service
- Fixed the error in importing libraries of
-
0.2.0:
- Introducing
md_to_codeblock
tool, support extracting code blocks in Markdown to Python, JSON, JS, BASH, SVG, HTML, XML, MARKDOWN files. - Introducing
md_to_rst
tool, support reStructuredText.rst
file format as destination file format
- Introducing
-
0.1.x:
- Introducing
md_to_pptx
tool, support PowerPoint.pptx
file format as destination file format
- Introducing
-
0.0.x:
- Published to Dify Marketplace
- support exporting Markdown to DOCX, PPTX, XLSX, PDF, HTML, MD, CSV, JSON, XML, LaTex files
This Dify plugin uses the following open sourced projects:
- md2pptx , MIT License
- pypandoc, MIT License
- pandas, BSD 3-Clause License
- python-pptx, MIT License
- xhtml2pdf, Apache License 2.0
- Apache License 2.0
This plugin collects no data.
All the file transformations are completed locally. NO data is transmitted to third-party services.