@rekurt/openkline - v0.2.0
    Preparing search index...

    Function computeLayout

    • Compute chart layout from container dimensions.

      paneCount is the number of sub-pane indicator bands stacked under the main chart area. Each consumes INDICATOR_PANE_HEIGHT px vertically. We cap the total reserved height so the main area never shrinks below MIN_MAIN_AREA_HEIGHT — if the user asks for more panes than fit, panes are simply rendered shorter.

      hasLeftAxis (B2) reserves a PRICE_AXIS_WIDTH strip on the LEFT for the optional secondary price axis and shifts chartLeft right by that much. It defaults to false, so the common single-axis layout is byte-for-byte identical (leftAxisWidth: 0, chartLeft: 0).

      Parameters

      • width: number
      • height: number
      • paneCount: number = 0
      • hasLeftAxis: boolean = false

      Returns ChartLayout