Skip to main content

Markdown typography engine for WeChat, Xiaohongshu and more — 25 themes, zero external dependencies, fully offline.

Project description

✒️ inkpress

Typography engine for creators — 为创作者打造的排版引擎

Markdown → WeChat / Xiaohongshu / More platforms

25 themes · Zero deps · Free forever

🌐 Live Demo · 📦 Install · 📖 Docs


Features / 特性

  • 25 curated themes across 5 series — classic, oriental, magazine, social, and more
  • Zero dependencies — pure Python core, no external API calls
  • Fully offline — works anywhere, even without internet
  • WeChat optimized — copy-paste directly into WeChat Official Account editor
  • Xiaohongshu ready — formatted content for Xiaohongshu long posts (coming soon)
  • YAML themes — fully customizable, create your own in minutes
  • JS renderer — browser-based 1:1 mirror of the Python engine for live preview

Install / 安装

pip install markdown pygments pyyaml

CLI usage / 命令行使用:

# Convert an article / 转换文章
python -m inkpress convert article.md -t aurora -o output.html

# List all themes / 查看所有主题
python -m inkpress themes

# Start local preview server / 启动本地预览
python -m inkpress serve

Python API:

from inkpress import convert, list_themes

# One-liner / 一行搞定
html = convert("# Hello\nWorld", theme="aurora")

# Browse themes / 浏览主题
for name, desc in list_themes().items():
    print(f"{name}: {desc}")

Theme Gallery / 主题画廊

5 series, 25 handcrafted themes — browse them all online →

5 大系列,25 个精品主题 — 在线预览 →

Series / 系列 Themes / 主题
Classic / 经典 default, minimal, mono, elegant-serif, aurora, ocean, sunset, latte, bluehl, corporate, forest, sunshine
Oriental / 东方 chinese-ink, zen-garden, tang-poetry, sanguo, inkwash
Magazine / 杂志 vogue, bauhaus, editorial, academy
Social / 社交 xiaohongshu, mint, mint-highlight, sakura

Custom Themes / 自定义主题

Drop a YAML file into ~/.inkpress/themes/ — it's that simple.

把 YAML 文件放到 ~/.inkpress/themes/ 即可。

name: "My Theme"
description: "A custom theme"
series: "custom"

h1:
  style: |
    font-size: 24px;
    color: #333;
    font-weight: bold;

paragraph:
  style: |
    font-size: 15px;
    line-height: 1.75;
    color: #444;

See themes/_template.yaml for the full field reference.

完整字段参考见 themes/_template.yaml


Project Structure / 项目结构

inkpress/          Python core engine / Python 转换引擎
themes/            YAML theme files / YAML 主题定义
showcase/          Static showcase site (GitHub Pages) / 展示网站
skills/inkpress/   Claude Code Skill definition
scripts/           Build scripts / 构建脚本

Use as Claude Code Skill

claude skill install /path/to/inkpress/skills/inkpress

Then say: "帮我用 aurora 主题排版这篇文章" / "Format this article with the aurora theme"


License

MIT — free for personal and commercial use.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

inkpress-0.1.0.tar.gz (45.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

inkpress-0.1.0-py3-none-any.whl (80.6 kB view details)

Uploaded Python 3

File details

Details for the file inkpress-0.1.0.tar.gz.

File metadata

  • Download URL: inkpress-0.1.0.tar.gz
  • Upload date:
  • Size: 45.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.7

File hashes

Hashes for inkpress-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c4e4c298c1a83094bbdfbf3f5c54d16c5a15445ca5d199c0cf4ba840fcbabd09
MD5 6e127002f0d68046a66a22050ffbc354
BLAKE2b-256 7c5a6296bf3b41f92ba8c3fc6ffe93b80b3881c97bb9255612fd8772cd7bd084

See more details on using hashes here.

File details

Details for the file inkpress-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: inkpress-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 80.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.7

File hashes

Hashes for inkpress-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 386506d8fd556725a0fd2160936daf4900bc5369a42760c4e2add3aa3ec78dd1
MD5 51e8d4466555e5439590b5b58d20985a
BLAKE2b-256 ba370ed3f53b61254d06203067aaf42262c6c78fc59deba40309df4f73fc1e03

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page