Function distribute_variable_row

  • Distribute diagrams in a variable width row if there is a diagram that is wider than the container width, it will be placed in a separate row

    Parameters

    • diagrams: Diagram[]

      diagrams to be distributed

    • container_width: number

      width of the container

    • vertical_space: number = 0

      space between the diagrams vertically (default = 0)

    • horizontal_space: number = 0

      space between the diagrams horizontally (default = 0)

    • vertical_alignment: VerticalAlignment = 'center'

      vertical alignment of the diagrams (default = 'center') alignment can be 'top', 'center', or 'bottom'

    • horizontal_alignment: HorizontalAlignment = 'left'

      horizontal alignment of the diagrams (default = 'left') alignment can be 'left', 'center', or 'right'

    Returns Diagram