- JavaScript 77.3%
- TypeScript 22.1%
- CSS 0.4%
- Shell 0.2%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| .forgejo/workflows | ||
| .githooks | ||
| client | ||
| routes | ||
| scripts | ||
| vendor | ||
| .env.example | ||
| .gitignore | ||
| block_render.test.ts | ||
| block_render.ts | ||
| compose.dev.yml | ||
| embed_asset_patterns.ts | ||
| limedoc.project.json | ||
| mindelixir.plugin.json | ||
| mindelixir.ts | ||
| mindelixir_client.test.ts | ||
| mindelixir_client.ts | ||
| mindelixir_client_adapter.ts | ||
| mindelixir_image_box.test.ts | ||
| mindelixir_image_box.ts | ||
| mindelixir_image_measure.test.ts | ||
| mindelixir_image_measure.ts | ||
| mindelixir_markdown.ts | ||
| mindelixir_node_metadata.test.ts | ||
| mindelixir_node_metadata.ts | ||
| mindelixir_node_sync.test.ts | ||
| mindelixir_node_sync.ts | ||
| mindelixir_render_constants.ts | ||
| mindelixir_render_prepare.test.ts | ||
| mindelixir_render_prepare.ts | ||
| mindelixir_theme.ts | ||
| mindelixir_topic_image_constants.ts | ||
| mindelixir_topic_image_parse.test.ts | ||
| mindelixir_topic_image_parse.ts | ||
| mindelixir_topic_image_plugin.ts | ||
| mindelixir_topic_image_uri.test.ts | ||
| mindelixir_topic_image_uri.ts | ||
| mindelixir_topic_markdown.test.ts | ||
| mindelixir_topic_markdown.ts | ||
| mindelixir_topic_markdown_glue.ts | ||
| mindmap-editor.css | ||
| mindmap_block_editor.tsx | ||
| mindmap_block_preview_client.tsx | ||
| mindmap_directive.test.ts | ||
| mindmap_directive.ts | ||
| mindmap_editor_modal.tsx | ||
| mindmap_editor_tool.tsx | ||
| mindmap_host_doc.ts | ||
| mindmap_open_editor.tsx | ||
| mindmap_open_viewer.tsx | ||
| mindmap_poll_hydrator.tsx | ||
| mindmap_preview_poll.ts | ||
| mindmap_print_invalidate.test.ts | ||
| mindmap_render_inflight.test.ts | ||
| mindmap_render_inflight.ts | ||
| mindmap_save_toast.ts | ||
| mindmap_viewer_modal.tsx | ||
| plugin.devkit.json | ||
| README.md | ||
| vendor.lock.json | ||
| web_render_result_sink.test.ts | ||
Mind Elixir Mind Maps
Embed and edit Mind Elixir mind maps in documents. Requires the web-render plugin for server-side WebP prerender.
Requirements
- Docker (or Podman with
DOCKER_CMD=podman) - web-render plugin (runtime dependency; install via store or bind-mount)
Quick start
# 1. Pull the dev image and set up .env
./ldcmd setup
# 2. Start the dev environment (app + Redis)
./ldcmd up
# 3. Install web-render (required dependency)
./ldcmd plugin install web-render
# 4. Open http://localhost:5173 in your browser
# 5. Edit plugin sources — HMR applies automatically
# 6. Run tests
./ldcmd test
# 7. Check types and import boundaries
./ldcmd check
Features
- Block type
.mindmap(application/vnd.mind-elixir+json) - Markdown directive
::mindmap path/to/map.mindmap ::: - Viewport editor and interactive viewer modals
- web-render server WebP prerender (light + dark
.map-canvasscreenshots) - Lime light/dark Mind Elixir themes
Directory layout
mindelixir.plugin.json # Plugin manifest
mindelixir.ts # Server entry (defineLimedocPlugin)
mindmap_editor_tool.tsx # Browser client (builds to client/*.js)
client/ # Pre-built browser bundles (committed)
vendor/ # Vendored Mind Elixir IIFE + CSS
limedoc.project.json # Store metadata (package download URLs)
compose.dev.yml # Dev compose (uses the published limedoc-dev image)
ldcmd # Bridge script — the only thing you run on your host
.env.example # Env var template — copy to .env and fill in OIDC values
ldcmd commands
| Command | What it does |
|---|---|
./ldcmd setup |
Pull limedoc-dev image, copy .env.example → .env |
./ldcmd up |
Start dev environment |
./ldcmd down |
Stop dev environment |
./ldcmd logs [service] |
Follow container logs |
./ldcmd sh [service] |
Open shell in container (default: app-dev) |
./ldcmd test |
Run plugin tests (installs web-render in CI) |
./ldcmd fmt |
Format sources |
./ldcmd lint |
Lint sources |
./ldcmd check |
Type-check + import boundary check |
./ldcmd pack |
Build zip + sha256 (CI also publishes sig.json) |
./ldcmd publish |
Pack and upload (needs .forgejo.env / PACKAGE_TOKEN) |
./ldcmd plugin install <id> |
Install a plugin dependency into the running env |
./ldcmd plugin ls |
List installed plugins |
Vendor
deno run -A scripts/bundle-vendor.ts
# or via
deno task plugin:build -- plugins/mindelixir.plugin
Pins mind-elixir@5.15.1 (vanilla full IIFE) and KaTeX CSS.
Building client bundles
# Inside the container (run after editing .tsx files)
./ldcmd sh
deno task plugin:build -- /limedoc/plugins/mindelixir.plugin
Tests
./ldcmd test
# or from the limedoc app root:
deno task test:mindelixir
Plugin tests that exercise the web-render result sink require web-render on
disk. CI installs it via deno task packs:install -- web-render before tests.
Developing with plugin dependencies
This plugin declares "requires": ["web-render"] in its manifest.
1. Install via ldcmd (easiest, needs the app running)
./ldcmd up
./ldcmd plugin install web-render
Set PACKAGE_STORE_URL in .env:
PACKAGE_STORE_URL=https://git.belowtoxic.cloud/api/packages/limedoc-plugins
2. Local bind-mount (no running app needed)
Check out or unzip web-render next to this directory, then add a volume to
compose.dev.yml:
app-dev:
volumes:
- .:/limedoc/plugins/mindelixir.plugin
- ../web-render.plugin:/limedoc/plugins/web-render.plugin
Then ./ldcmd up — the app loads all *.plugin directories in plugins/.
CI / CD
Push to main → Forgejo Actions runs .forgejo/workflows/publish.yml:
- Installs web-render from the signed store catalog
- Tests pass inside the
limedoc-devcontainer - Client bundles built; boundary check passes
plugin:packproducesmindelixir-{version}.zip+.sha256- OpenBao signs the content hash →
mindelixir-{version}.sig.json - Zip, sha256, and sig.json uploaded to the generic package registry (store)
- Same artifacts attached to a Forgejo Release
v{version}(operators)
The app installs plugins from the generic package registry at PACKAGE_STORE_URL.
Using Podman instead of Docker
# In .env (or export before running):
DOCKER_CMD=podman
./ldcmd up
ldcmd detects podman compose automatically.