Initialize local Tabularium documentation monorepo

This commit is contained in:
2026-10-26 19:20:07 +08:00
commit 5ceb4e57aa
27 changed files with 5582 additions and 0 deletions
+13
View File
@@ -0,0 +1,13 @@
[project]
name = "endor-figures"
version = "0.1.0"
description = "Local, reproducible Endor documentation figures"
requires-python = ">=3.11"
dependencies = ["drawsvg>=2.4,<3"]
[project.scripts]
endor-figures = "endor_figures.cli:main"
[build-system]
requires = ["hatchling>=1.27,<2"]
build-backend = "hatchling.build"
@@ -0,0 +1 @@
"""Reproducible figures for the Endor documentation."""
+34
View File
@@ -0,0 +1,34 @@
"""Generate local SVG assets without external fonts or rendering services."""
from pathlib import Path
import drawsvg as draw
def main() -> None:
root = Path(__file__).resolve().parents[4]
output = root / "apps/docs/public/figures/workflow.svg"
output.parent.mkdir(parents=True, exist_ok=True)
diagram = draw.Drawing(960, 240)
diagram.append_title("Local figure workflow")
diagram.append(draw.Rectangle(0, 0, 960, 240, fill="#f5f5f0", rx=16))
diagram.append(draw.Text("TABULARIUM / FIGURE WORKFLOW", 16, 32, 42,
fill="#57534e", font_family="sans-serif"))
for index, (title, subtitle) in enumerate([
("Python source", "tools/figures"),
("SVG asset", "apps/docs/public/figures"),
("Local documentation", "content/docs"),
]):
x = 32 + index * 312
diagram.append(draw.Rectangle(x, 80, 272, 120, rx=12,
fill="#ffffff", stroke="#a8a29e"))
diagram.append(draw.Text(title, 20, x + 18, 126,
fill="#134e4a", font_family="sans-serif"))
diagram.append(draw.Text(subtitle, 14, x + 18, 164,
fill="#57534e", font_family="monospace"))
if index < 2:
diagram.append(draw.Line(x + 280, 140, x + 302, 140,
stroke="#0f766e", stroke_width=2))
diagram.append(draw.Lines(x + 297, 135, x + 302, 140,
x + 297, 145, fill="none",
stroke="#0f766e", stroke_width=2))
diagram.save_svg(str(output))
print(f"Generated {output.relative_to(root)}")
+23
View File
@@ -0,0 +1,23 @@
version = 1
revision = 3
requires-python = ">=3.11"
[[package]]
name = "drawsvg"
version = "2.4.2"
source = { registry = "https://pypi.org/simple" }
sdist = { url = "https://files.pythonhosted.org/packages/86/ec/a88a29dc4e380c6283fa6922a21c715ec40bf40f7b53859f8a104a7cbe26/drawsvg-2.4.2.tar.gz", hash = "sha256:5efd8bcdc2c2400425e7fb71b4b80d8fdd83b1dc810f790f58a165df33ddd303", size = 733210, upload-time = "2026-08-12T03:24:43.679Z" }
wheels = [
{ url = "https://files.pythonhosted.org/packages/15/5a/c47c10de42c49a3a9957123d77e5692b56b4fbc342b55285b52c41a8f1c1/drawsvg-2.4.2-py3-none-any.whl", hash = "sha256:b1c101e187aa395cb13c039549e4f26fb7b7ee03974f53dc9798436463781bf1", size = 44175, upload-time = "2026-08-12T03:24:42.531Z" },
]
[[package]]
name = "endor-figures"
version = "0.1.0"
source = { editable = "." }
dependencies = [
{ name = "drawsvg" },
]
[package.metadata]
requires-dist = [{ name = "drawsvg", specifier = ">=2.4,<3" }]