Skip to content

Commit

Permalink
Fix responsive for Sankey
Browse files Browse the repository at this point in the history
  • Loading branch information
philippjfr committed Jan 10, 2020
1 parent 6ba6709 commit f49a150
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion holoviews/plotting/bokeh/__init__.py
Expand Up @@ -262,7 +262,7 @@ def colormap_generator(palette):
options.EdgePaths = Options('plot', tools=['hover', 'tap'])
options.Sankey = Options(
'plot', xaxis=None, yaxis=None, inspection_policy='edges',
selection_policy='nodes', width=1000, height=600, show_frame=False
selection_policy='nodes', show_frame=False
)
options.Sankey = Options(
'style', node_nonselection_alpha=0.2, node_size=10, edge_nonselection_alpha=0.2,
Expand Down
8 changes: 8 additions & 0 deletions holoviews/plotting/bokeh/sankey.py
Expand Up @@ -40,6 +40,14 @@ class SankeyPlot(GraphPlot):
node_sort = param.Boolean(default=True, doc="""
Sort nodes in ascending breadth.""")

width = param.Integer(default=1000, allow_None=True, bounds=(0, None), doc="""
The width of the component (in pixels). This can be either
fixed or preferred width, depending on width sizing policy.""")

height = param.Integer(default=600, allow_None=True, bounds=(0, None), doc="""
The height of the component (in pixels). This can be either
fixed or preferred height, depending on height sizing policy.""")

# Deprecated options

color_index = param.ClassSelector(default=2, class_=(basestring, int),
Expand Down

0 comments on commit f49a150

Please sign in to comment.