Spaces:
Running
Running
1one2two commited on
Commit ·
bf72dba
1
Parent(s): ffae8c1
feat: 編輯 README.md
Browse files6 unmodified lines789106 unmodified linespinned: false---Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference6 unmodified lines78910111213141516171819202122232425262728293031323334353637383940414243446 unmodified linespinned: false---# md / ppt同一個 Hugging Face Space 提供兩個 Gradio 頁面:- `/`:將 Markdown 轉成可編輯的 PPTX、PDF 與 PDF 頁面預覽。- `/template`:檢查 PowerPoint Slide Layout / Placeholder,並另存可供 Pandoc `--reference-doc` 使用的新 PPTX。## Markdown 轉換器支援上傳 Markdown 或直接貼上內容,可選擇自訂 PowerPoint 模板。外部圖片僅接受公開 HTTPS URL 或通過驗證的 data URI,並包含 SSRF、MIME、像素、檔案大小、redirect 與 timeout 限制。轉換使用 Pandoc,PDF 使用 LibreOffice,預覽使用 Poppler。## PowerPoint 模板工具模板工具會遍歷所有 Slide Master / Slide Layout,以 OOXML `<p:ph>` 判斷 Placeholder type 與 idx,檢查 Pandoc 的七個標準 Layout:1. Title Slide2. Title and Content3. Section Header4. Two Content5. Comparison6. Content with Caption7. Blank輸出只修改選定的 `layout.name` 並另存新檔;不覆寫來源、不搬移 Master/Layout、不重建 Theme,也不新增、刪除或移動 Placeholder。## Local / Docker```bashdocker build -t markdown2ppt .docker run --rm -p 7860:7860 markdown2ppt```啟動後可直接開啟 `/` 或 `/template`;部署時不需要設定或寫死 Space domain。Runtime Python dependencies are pinned in `requirements.txt`. The Docker image also installs Pandoc, LibreOffice, CJK fonts, and Poppler.
README.md+35-1