Advice on configuring layouts for Matplotlib

Hi. Now I have a basic panel server going I’d like matplotlib figures to resize, I think I mean scale, so that they will fit on the client screen. Right now it’s done for my own use 27" screen but now I want to share the output to others many of whom will of course be on phones.

As of now I set fig size = xxx, set matplotlib = fig and return fig,
The figures are placed in a row or a column and the row or column can be part of another row or column all of which goes on a tab. EG

leftc = pn.Card(the_states,the_days,  bound_plot1)
rightc  = pn.Column(the_state,  bound_plot2)
leftb = pn.Column(the_state2,  bound_plot3)
rightb  = pn.Column(the_state3,  bound_plot4)
leftb2 = pn.Column(bound_nsw_trans_cht)
t2_cl = pn.Column(vre_by_year) #static
t2_cr = pn.Column(vre_by_fuel)
t2_bl = pn.Column()
t2_br = pn.Column()
t3_lef =pn.Column()
# rows
top = pn.Row (title_pane  ) #width =colwidth
centre = pn.Row(leftc,rightc )
bottom = pn.Row (leftb,rightb  )
centre2 = pn.Row(t2_cl,t2_cr  )
bottom2 = pn.Row(t2_bl,t2_br  )
bottom3 = pn.Row(leftb2)

Can I use a template, or should I set the layout properties of the row or column, or place all the items in cards to start with and set their properties? Just looking for suggestions to avoid a lot of trial and errors.

TIA

Ok I did some experimentation. I can see immediately it’s not that easy. an approach that is producing acceptable result to a point and so far is to put plots in columns with a sizing_mode = scale_both and (for a 2 component wide) approach put two columns in a row with a fixed height.

Might post a couple of screen shots of the results later. Easy to get side tracked from the day job.