Skip to content
daisyBlazor

Column3DChart

Columns (or bars) drawn as 3D prisms on a floor in front of a back wall, side by side or stacked, for a dashboard that wants depth. The top and side of each column are shaded from its colour with color-mix, so they follow any theme. D3 scales place the columns.
Specialised
Cover · <Column3DChart>
3D column chartMon 42, Tue 58, Wed 51, Thu 66, Fri 37 MonTueWedThuFri010203040506070Mon: 42 Tue: 58 Wed: 51 Thu: 66 Fri: 37

Examples

Basic

Labels name the categories and each ChartSeries is a colour, one column per series in each category; the gridlines run across the back wall.

New workspaces per quarter
New workspaces per quarterFree: Q1 420, Q2 510, Q3 488, Q4 602; Pro: Q1 180, Q2 214, Q3 251, Q4 290; Enterprise: Q1 34, Q2 41, Q3 39, Q4 52 Q1Q2Q3Q40100200300400500600700Free · Q1: 420 Pro · Q1: 180 Enterprise · Q1: 34 Free · Q2: 510 Pro · Q2: 214 Enterprise · Q2: 41 Free · Q3: 488 Pro · Q3: 251 Enterprise · Q3: 39 Free · Q4: 602 Pro · Q4: 290 Enterprise · Q4: 52
Free Pro Enterprise
website/Examples/Charts/Column3DChartBasicExample.razor Source

Stacked, sideways

Stacked="true" piles the series into one column, Horizontal="true" lays the bars out top to bottom, and Depth (0 to 1, a share of the column's width) sets how deep the prisms are.

3D bar chartFree: Europe 1,840, North America 2,210, Asia Pacific 1,130, Latin America 620, Africa 240; Pro: Europe 760, North America 940, Asia Pacific 410, Latin America 190, Africa 70; Enterprise: Europe 120, North America 160, Asia Pacific 64, Latin America 22, Africa 8 05001k1.5k2k2.5k3k3.5kEuropeNorth AmericaAsia PacificLatin AmericaAfricaFree · Africa: 240 Pro · Africa: 70 Enterprise · Africa: 8 Free · Latin America: 620 Pro · Latin America: 190 Enterprise · Latin America: 22 Free · Asia Pacific: 1,130 Pro · Asia Pacific: 410 Enterprise · Asia Pacific: 64 Free · North America: 2,210 Pro · North America: 940 Enterprise · North America: 160 Free · Europe: 1,840 Pro · Europe: 760 Enterprise · Europe: 120
Free Pro Enterprise
website/Examples/Charts/Column3DChartStackedExample.razor Source

Playground

New workspaces per quarter
New workspaces per quarterFree: Q1 420, Q2 510, Q3 488, Q4 602; Pro: Q1 180, Q2 214, Q3 251, Q4 290; Enterprise: Q1 34, Q2 41, Q3 39, Q4 52 Q1Q2Q3Q40100200300400500600700Free · Q1: 420 Pro · Q1: 180 Enterprise · Q1: 34 Free · Q2: 510 Pro · Q2: 214 Enterprise · Q2: 41 Free · Q3: 488 Pro · Q3: 251 Enterprise · Q3: 39 Free · Q4: 602 Pro · Q4: 290 Enterprise · Q4: 52
Free Pro Enterprise
<Column3DChart
               Title="New workspaces per quarter"
               Labels="@_quarters"
               Series="@_series" />

@code {
    private readonly string[] _quarters = ["Q1", "Q2", "Q3", "Q4"];

    private readonly ChartSeries[] _series =
    [
        new("Free", [420, 510, 488, 602]),
        new("Pro", [180, 214, 251, 290]),
        new("Enterprise", [34, 41, 39, 52]),
    ];
}

API

<Column3DChart>

DaisyBlazor.Charts

Parameters

  • AspectRatio double
    = 1.78

    Width divided by height. The chart keeps this shape at any width; its text keeps its size.

  • Data IReadOnlyList<ChartDataPoint>
    = null

    Flat data points, one column each; used when no Series are supplied.

  • Depth double
    = 0.5

    How deep a column is, as a share of its width (0 to 1).

  • Horizontal bool
    = false

    Lay the bars out sideways, categories down the left side.

  • Labels IReadOnlyList<string>
    = null

    Category labels for Series.

  • RowHeight double?
    = null

    Height of each row in px, for a chart that lays its categories out as rows (horizontal bars, a Gantt's lanes, a heatmap's rows…): its height then follows its number of rows instead of AspectRatio, so a long list keeps readable rows at any width. A chart, or an orientation, without rows ignores it.

  • Series IReadOnlyList<ChartSeries>
    = null

    Series of values, index-aligned with Labels. Takes precedence over Data.

  • ShowLegend bool
    = true

    Show a legend when there is more than one series.

  • ShowTitle bool
    = true

    Draw Title as a visible heading above the chart (the default); false keeps it only as the chart's accessible name, for a chart inside a card that already has a heading.

  • Stacked bool
    = false

    Stack the series in one column per category instead of side by side.

  • Title string
    = null

    Optional heading rendered above the chart; it is also the chart's accessible name.

  • Width string
    = "100%"

    CSS width of the chart wrapper.

  • Class string
    = null

    Additional CSS classes merged onto the w-full wrapper.

  • Style string
    = null

    Inline styles appended after the width on the wrapper.

Something went wrong while running the docs. Reload