Skip to content

giuseppe-trisciuoglio/developer-kit / plugins/developer-kit-core/skills/drawio-logical-diagrams

drawio-logical-diagrams

Verified

Creates professional logical flow diagrams and logical system architecture diagrams using draw.io XML format (.drawio files). Use when creating: (1) logical flow diagrams showing data/process flow between system components, (2) logical architecture diagrams representing system structure without cloud provider specifics, (3) BPMN process diagrams, (4) UML diagrams (class, sequence, activity), (5) data flow diagrams (DFD), (6) decision flowcharts, or (7) system interaction diagrams. This skill focuses on generic/abstract representations, not AWS/Azure-specific architectures (use aws-drawio-architecture-diagrams for cloud diagrams).

references/layout-best-practices.md

View on GitHub
# Layout Best Practices for Draw.io Diagrams

## Flow Direction

1. **Consistent direction**: Choose left-to-right OR top-to-bottom and stick with it
2. **Primary flow**: Main process flows left-to-right or top-to-bottom
3. **Return loops**: Route return paths below (for L-R) or to the right (for T-B)

**Example:**
```
Left-to-Right:    Top-to-Bottom:
  A → B → C          A
  │   ↓   │          ↓ B
  └───D───┘          ↓ C
                     ↓ D
```

## Spacing Guidelines

| Element | Spacing |
|---------|---------|
| Between elements (horizontal) | 40-60px |
| Between elements (vertical) | 40-60px |
| Inside containers | 20px margin from edges |
| Between grouped elements | 20-30px |
| Label from arrow | 15-20px |

## Grid Alignment

1. **Snap to grid**: All coordinates in multiples of 10
2. **Center alignment**: Center elements on their midpoint
3. **Edge alignment**: Align edges of related elements

**Example:**
```
Good:                Bad:
┌────┐  ┌────┐       ┌────┐
│ A  │  │ B  │       │ A  │  ┌────┐
└────┘  └────┘       └────┘  │ B  │
                             └────┘
```

## Label Placement

| Arrow Direction | Label Position |
|----------------|----------------|
| Horizontal (→) | Above the arrow |
| Vertical (↓)   | Right of the arrow |
| Diagonal       | At the midpoint, offset slightly |

**Tips:**
- Use white background for labels on arrows: `labelBackgroundColor=#ffffff`
- Keep labels short (1-3 words)
- Use fontSize 10-11 for connector labels

## Container Grouping

1. **Purpose**: Group related elements visually
2. **Style**: Use rounded rectangles with gray fill
3. **Hierarchy**: Nest containers for sub-groups

**Example:**
```
┌─────────────────────────────────┐
│     Service Layer               │
│  ┌──────────┐  ┌──────────┐    │
│  │ Service A│  │ Service B│    │
│  └──────────┘  └──────────┘    │
└─────────────────────────────────┘
```

## Balance and Composition

1. **Center the diagram**: Keep main flow centered on canvas
2. **Avoid extreme whitespace**: Don't leave large empty areas
3. **Symmetry**: Use symmetrical layouts for parallel processes
4. **Weight distribution**: Balance elements visually

## Connector Routing

1. **Minimize bends**: Use straight lines when possible
2. **Orthogonal routing**: Use right-angle bends (orthogonalEdgeStyle)
3. **Avoid crossings**: Route connectors to minimize crossings
4. **Clear direction**: Arrowheads should clearly show flow direction

## Visual Hierarchy

1. **Size hierarchy**: Important elements can be slightly larger
2. **Color coding**: Use consistent colors for element types
3. **Font sizing**: 12-14px for primary labels, 10-11px for annotations
4. **Bold for emphasis**: Use `fontStyle=1` for important elements

## Accessibility

1. **High contrast**: Ensure text is readable against background
2. **Don't rely on color alone**: Use symbols and labels
3. **Text size**: Minimum 10-11px for readability
4. **Labels on all shapes**: Every shape should have a clear label

## Common Layout Patterns

### Sequential Flow
```
A → B → C → D
```
Simple left-to-right or top-to-bottom flow.

### Branching Flow
```
    A
    ↓
   ┌──┴──┐
   B     C
   └──┬──┘
     ↓
     D
```
Diamond decision point with branches.

### Parallel Processes
```
  A
┌─┴─┐
B   C
└─┬─┘
  D
```
Parallel activities that converge.

### Layered Architecture
```
┌───────────┐
│  Layer 1  │
├───────────┤
│  Layer 2  │
├───────────┤
│  Layer 3  │
└───────────┘
```
Horizontal layers with vertical flow.

### Hub and Spoke
```
    ┌─B─┐
    │   │
  A-─HUB─┐D
    │   │
    └─C─┘
```
Central component with connections.

## Canvas Size

**Standard sizes:**
- A4 Landscape: 1169 x 827 px
- A4 Portrait: 827 x 1169 px
- A3 Landscape: 1654 x 1169 px
- Letter Landscape: 1100 x 850 px

**Tip:** Set `pageWidth` and `pageHeight` in mxGraphModel to match your needs.

## Common Mistakes to Avoid

1. ❌ Inconsistent flow direction
2. ❌ Elements too close together
3. ❌ Misaligned connectors
4. ❌ Labels overlapping elements
5. ❌ Too many crossing connectors
6. ❌ Inconsistent element sizes
7. ❌ Poor color contrast
8. ❌ Missing labels on shapes
writing-skillsobra/superpowersUse when creating new skills, editing existing skills, or verifying skills work before deploymentStars: 322kUpdated Claude CodeCodexVerifiedInstall
xlsxanthropics/skillsUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved.Stars: 198kUpdated Claude CodeCodexVerifiedInstall
shipping-and-launchaddyosmani/agent-skillsPrepares production launches. Use when preparing to deploy to production, or when asking what needs to be in place before shipping. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
childhoodthedotmack/claude-memBabysit a shipped release after merge, publication, or deployment. Verify published packages, production behavior, installed plugins, and late CI or user reports until the observation window is clean; use babysit for PR readiness before release.Stars: 118kUpdated Claude CodeCodexVerifiedInstall