Class: RailsCharts::SankeyChart
Constant Summary
Constants inherited
from BaseChart
BaseChart::CHART_JS_PATTERN
Instance Attribute Summary
Attributes inherited from BaseChart
#chart_id, #container_id, #data, #debug, #height, #klass, #locale, #options, #other_options, #renderer, #style, #theme, #vertical, #width
Instance Method Summary
collapse
Methods inherited from BaseChart
#axises, #initialize, #js_code, #option, #x_axis, #y_axis
Instance Method Details
#build_options ⇒ Object
8
9
10
|
# File 'lib/rails_charts/sankey_chart.rb', line 8
def build_options
super.except(:xAxis, :yAxis)
end
|
#defaults ⇒ Object
20
21
22
23
24
25
26
27
28
|
# File 'lib/rails_charts/sankey_chart.rb', line 20
def defaults
{
series: {
emphasis: {
focus: 'adjacency'
}
}
}
end
|
#generate_series_options ⇒ Object
12
13
14
15
16
17
18
|
# File 'lib/rails_charts/sankey_chart.rb', line 12
def generate_series_options
{
data: data[:data],
links: data[:links],
type: type
}
end
|
#type ⇒ Object
4
5
6
|
# File 'lib/rails_charts/sankey_chart.rb', line 4
def type
'sankey'
end
|