Sha256: 27f3dd9363d355362700323fb47c08db4c82a63222b3f91c533bdaaec48c4c2b

Contents?: true

Size: 1.05 KB

Versions: 135

Compression:

Stored size: 1.05 KB

Contents

<% data = [{
  name: 'Role',
  data: [0, 200, 300, 654, 656],
}, {
  name: 'Company',
  data: [150, 524, 320, 440, 500],
}] %>

<% bar_graph_options = {
  customOptions: {
    yAxis: {
      tickInterval: 5,
    },
    xAxis: {
      categories: [
        raw(pb_rails("icon", props: { icon: "frown", color: "error", size: "2x" })),
        raw(pb_rails("icon", props: { icon: "frown", color: "warning", size: "2x" })),
        raw(pb_rails("icon", props: { icon: "frown-open", color: "neutral", size: "2x" })),
        raw(pb_rails("icon", props: { icon: "smile", color: "category_7", size: "2x" })),
        raw(pb_rails("icon", props: { icon: "smile-beam", color: "success", size: "2x" }))
      ],
      labels: {
        useHTML: true,
        sytle: {
          fontSize: '1.4em',
        },
        y: 42,
      },
    },
    legend: {
      itemMarginTop: 62,
    },
  } 
} %>

<%= pb_rails("bar_graph", props: {
    chart_data: data,
    id: "bar-default",
    legend: true,
    title: 'Bar Graph with Custom Overrides',
    custom_options: bar_graph_options
}) %>

Version data entries

135 entries across 135 versions & 2 rubygems

Version Path
playbook_ui_docs-14.10.0.pre.alpha.play1662cssbargraph5201 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.10.0.pre.alpha.play1662cssbargraph5201 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.9 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.9 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.10.0.pre.alpha.play1662cssbargraph5200 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.10.0.pre.alpha.play1662cssbargraph5200 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.8 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.8 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.7 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.7 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.6 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.6 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.5 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.5 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.10.0.pre.alpha.play1662cssbargraph5193 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.10.0.pre.alpha.play1662cssbargraph5193 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.4 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.4 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui_docs-14.11.0.pre.rc.3 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb
playbook_ui-14.11.0.pre.rc.3 app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_custom_rails.html.erb