PyG2Plot icon indicating copy to clipboard operation
PyG2Plot copied to clipboard

notebook.html overflow 样式问题

Open xvvhang opened this issue 4 years ago • 1 comments

在 iframe 中渲染时,notebook.html 中 overflow 属性会影响外部样式,导致外部 window 不能滚动

xvvhang avatar Jul 05 '21 03:07 xvvhang

If using PyG2Plot with PyWebIO together This is the solution that worked for me:

from pyg2plot import Plot from pywebio.output import

body_css = """

"""

''' Column chart ''' column = Plot('Column') column.set_options({ "appendPadding": 32, "data": data, "xField": "city", "yField": "value", "seriesField": "type", "isGroup": True, "columnStyle": { "radius": [20, 20, 0, 0], }, "legend": { "position": "top" } })

''' Inject css before chart ''' pywebio.output.put_html(body_css) put_html(column.render_notebook())

Shira-Naim avatar Feb 15 '23 16:02 Shira-Naim