Relationship styles

By default all relationships are styled as dashed grey lines.

Styling all relationships

To change the style for all relationships, add a relationship style for the Relationship tag.

workspace {

    model {
        a = softwareSystem "A"
        b = softwareSystem "B"
        c = softwareSystem "C"

        a -> b
        b -> c
    }

    views {
        systemLandscape {
            include *
            autolayout lr
        }
        
        styles {
            relationship "Relationship" {
                color #ff0000
                dashed false
            }
        }
    }
    
}

Styling individual relationships

To change the style of an individual relationship:

  1. Tag the relationship.
  2. Add a relationship style for that tag.
workspace {

    model {
        a = softwareSystem "A"
        b = softwareSystem "B"
        c = softwareSystem "C"

        a -> b
        b -> c {
            tags "Tag 1"
        }
    }

    views {
        systemLandscape {
            include *
            autolayout lr
        }
        
        styles {
            relationship "Tag 1" {
                color #ff0000
                dashed false
            }
        }
    }
    
}

Notes

Please note that relationship styles are designed to work with the Structurizr diagram renderer (see Notation), and may not be fully supported by the PlantUML, Mermaid, etc export formats.


This site uses Just the Docs, a documentation theme for Jekyll.