Sizing_mode on label font size


I made a heatmap with Holoviews and overlaid labels onto it. I’d like to use this as part of a panel, and have its size adjust depending on the size of the application. I’ve managed to get the plot size to change, but the font size stays the same. How can I go about making the labels also adapt to the size of the application?


import pandas as pd
import panel as pn
import holoviews as hv
from holoviews import opts
import hvplot.pandas
import numpy as np 

demo_df = pd.DataFrame(0.01, index=np.arange(15), columns=np.arange(15))

heatmap = demo_df.hvplot.heatmap(colorbar=False, hover=False, xlabel="xLabel", ylabel="yLabel").opts(toolbar=None)
heatmap_with_labels = heatmap * hv.Labels(heatmap)
panel = pn.panel(heatmap_with_labels, sizing_mode='stretch_both')

Something with .apply.opts(fontscale=…) that is dependent on width / height I think