See https://github.com/altair-viz/altair/issues/1007 and https://github.com/jupyterlab/jupyterlab/issues/4897