Open MarcSkovMadsen opened 2 years ago
Appears to be fixed in 1.0rc3:
plot = get_plot(theme=get_theme())
pn.pane.Matplotlib(plot, min_height=600, sizing_mode="scale_height", align="center").servable()
pn.Column(
pn.pane.Matplotlib(plot, min_height=600, sizing_mode="scale_height", align="center"),
sizing_mode="stretch_both",
).servable()
Wait, guess that's not what you were asking for. I don't see how your requested behavior can work because alignment depends on the parent container.
panel: 0.12.6
I'm updating awesome-panel.org to use the proposed api of
I'm having trouble aligning the component center, primarily horizontally. As you can see below it can be done. But not via
pn.pane.Matplotlib(plot, height=600, sizing_mode="scale_height", align="center").servable()
. It is more cumbersome.I believe a lot of users would have difficulties figuring this out. It took me some time.
Solution
Make
pn.pane.Matplotlib(plot, height=600, sizing_mode="scale_height", align="center").servable()
align center