@diagrammo/dgmo 0.6.1 → 0.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/commands/dgmo.md +76 -0
- package/dist/cli.cjs +160 -159
- package/dist/index.cjs +780 -147
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +780 -147
- package/dist/index.js.map +1 -1
- package/docs/ai-integration.md +33 -50
- package/package.json +4 -3
- package/src/c4/layout.ts +68 -5
- package/src/cli.ts +124 -2
- package/src/er/classify.ts +206 -0
- package/src/er/layout.ts +259 -94
- package/src/er/renderer.ts +231 -17
- package/src/infra/layout.ts +60 -13
- package/src/infra/renderer.ts +375 -32
- package/src/initiative-status/layout.ts +46 -30
- package/.claude/skills/dgmo-chart/SKILL.md +0 -141
- package/.claude/skills/dgmo-flowchart/SKILL.md +0 -61
- package/.claude/skills/dgmo-generate/SKILL.md +0 -59
- package/.claude/skills/dgmo-sequence/SKILL.md +0 -104
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# dgmo — Diagrammo Diagram Assistant
|
|
2
|
+
|
|
3
|
+
You are helping the user author, render, and share diagrams using the `dgmo` CLI and `.dgmo` file format.
|
|
4
|
+
|
|
5
|
+
## What is dgmo?
|
|
6
|
+
|
|
7
|
+
`dgmo` is a CLI tool that renders `.dgmo` diagram files to PNG, SVG, or shareable URLs. Diagrams are written in a plain-text DSL.
|
|
8
|
+
|
|
9
|
+
## CLI Reference
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
dgmo <input.dgmo> [options]
|
|
13
|
+
cat input.dgmo | dgmo [options]
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Key options:
|
|
17
|
+
- `-o <file>` — output file; format inferred from extension (`.svg` → SVG, else PNG)
|
|
18
|
+
- `-o url` — output a shareable diagrammo.app URL
|
|
19
|
+
- `--theme <theme>` — `light` (default), `dark`, `transparent`
|
|
20
|
+
- `--palette <name>` — `nord` (default), `solarized`, `catppuccin`, `rose-pine`, `gruvbox`, `tokyo-night`, `one-dark`, `bold`
|
|
21
|
+
- `--copy` — copy the URL to clipboard (use with `-o url`)
|
|
22
|
+
- `--no-branding` — omit diagrammo.app branding from exports
|
|
23
|
+
- `--chart-types` — list all supported chart types
|
|
24
|
+
|
|
25
|
+
## Supported Chart Types
|
|
26
|
+
|
|
27
|
+
| Type | Use case |
|
|
28
|
+
|------|----------|
|
|
29
|
+
| `bar` | Categorical comparisons |
|
|
30
|
+
| `line` / `multi-line` / `area` | Trends over time |
|
|
31
|
+
| `pie` / `doughnut` | Part-to-whole |
|
|
32
|
+
| `radar` / `polar-area` | Multi-dimensional metrics |
|
|
33
|
+
| `bar-stacked` | Multi-series categorical |
|
|
34
|
+
| `scatter` | 2D data points or bubble chart |
|
|
35
|
+
| `sankey` | Flow / allocation |
|
|
36
|
+
| `chord` | Circular flow relationships |
|
|
37
|
+
| `function` | Mathematical expressions |
|
|
38
|
+
| `heatmap` | Matrix intensity |
|
|
39
|
+
| `funnel` | Conversion pipeline |
|
|
40
|
+
| `slope` | Change between two periods |
|
|
41
|
+
| `wordcloud` | Term frequency |
|
|
42
|
+
| `arc` | Network relationships |
|
|
43
|
+
| `timeline` | Events, eras, date ranges |
|
|
44
|
+
| `venn` | Set overlaps |
|
|
45
|
+
| `quadrant` | 2x2 positioning matrix |
|
|
46
|
+
| `sequence` | Message / interaction flows |
|
|
47
|
+
| `flowchart` | Decision trees, process flows |
|
|
48
|
+
| `class` | UML class hierarchies |
|
|
49
|
+
| `er` | Database schemas |
|
|
50
|
+
| `org` | Hierarchical tree structures |
|
|
51
|
+
| `kanban` | Task / workflow columns |
|
|
52
|
+
| `c4` | System architecture (context → container → component → deployment) |
|
|
53
|
+
| `initiative-status` | Project roadmap with dependency tracking |
|
|
54
|
+
|
|
55
|
+
## Your Workflow
|
|
56
|
+
|
|
57
|
+
When the user asks you to create or edit a diagram:
|
|
58
|
+
|
|
59
|
+
1. **Write or edit the `.dgmo` file** with the appropriate chart type and data.
|
|
60
|
+
2. **Render it** with `dgmo <file>.dgmo -o <file>.png` to verify it produces output without errors.
|
|
61
|
+
3. **Show the user** what was created and suggest a shareable URL with `dgmo <file>.dgmo -o url --copy` if they want to share it.
|
|
62
|
+
|
|
63
|
+
When the user asks for a **shareable link**, run:
|
|
64
|
+
```
|
|
65
|
+
dgmo <file>.dgmo -o url --copy
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## Getting Syntax Help
|
|
69
|
+
|
|
70
|
+
Run `dgmo --chart-types` to list types. For detailed syntax of a specific chart type, the best reference is the diagrammo.app documentation or existing `.dgmo` files in the project.
|
|
71
|
+
|
|
72
|
+
## Tips
|
|
73
|
+
|
|
74
|
+
- Default theme is `light` and default palette is `nord` — ask the user if they have a preference before rendering a final export.
|
|
75
|
+
- For C4 diagrams, use `--c4-level` to drill from context → containers → components → deployment.
|
|
76
|
+
- Stdin mode is useful for quick one-off renders: `echo "..." | dgmo -o out.png`
|